News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

How To: Get SMF SSI.php Stuff to Display on your Wordpress Blog

Started by devnet, August 21, 2008, 01:05:39 PM

Previous topic - Next topic

devnet

Quote from: fopmhx on January 22, 2010, 01:32:21 PM
Apologies for dredging such an old topic up, but it seems a better option than starting a new topic.

I've followed all the steps indicated above, but now have the error message:
Parse error: syntax error, unexpected T_IF in /home/innersen/public_html/*****/forum/Sources/Security.php on line 1

However line 1 od security.php is:
<?php

any advice would be greatly appreciated


You're either missing a semicolon or a close parenthesis in an expression in security.php.

My advice is to download a fresh copy of SMF and compare your file and the fresh file for differences.

solly

How do i go about reversing this method and displaying wordpress content on my smf pages ?

Bassically i have a global header which is built in the smf template and that header needs to display content from wordpress.

I have followed this method - http://codex.wordpress.org/Integrating_Wordpress_with_Your_Website [nofollow]

How ever i get this message when trying to use wordpress code

Fatal error: Call to undefined function wp_list_bookmarks() in C:\xampp\htdocs\forum\Sources\Load.php(1726) : eval()'d code on line 313

Has any body else run into this error before ?


Shaliza


jrmacstudios

I don't mean to drudge this up either, but I followed some of the same directions here hoping it to work and I get
QuoteFatal error: Call to undefined function allowedto() in /data/25/2/161/113/2487765/user/2724405/htdocs/forums/Sources/Load.php on line 1137

Gavin Chatt

Sry Admin,trying to search however this is the closest I've found.



Where do I add this, I've tried the first line on the header page but it fails when I try and use it, tried a few other locations as well but still the same issue. I've following the following from the http://www.simplemachines.org/community/ssi_examples.php

QuoteInclude Code

To use SSI.php in your page add at the very top of your page before the <html> tag on line 1 of your php file:
Code: [Select]
<?php require("SSI.php"); ?>

I've then gone to my WordPress theme and located the header page and tried to add in line one but as mentioned my site dies.

Header (header.php)
Quote<?php global $theme; ?><!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>>
<head profile="http://gmpg.org/xfn/11">
<meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" />
<title><?php $theme->meta_title(); ?></title>
<meta name="viewport" content="width=device-width, initial-scale=1.0" />

<?php $theme->hook('meta'); ?>
<link rel="stylesheet" href="<?php echo THEMATER_URL; ?>/css/reset.css" type="text/css" media="screen, projection" />
<link rel="stylesheet" href="<?php echo THEMATER_URL; ?>/css/defaults.css" type="text/css" media="screen, projection" />
<!--[if lt IE 8]><link rel="stylesheet" href="<?php echo THEMATER_URL; ?>/css/ie.css" type="text/css" media="screen, projection" /><![endif]-->

<link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="screen, projection" />

<?php if ( is_singular() ) { wp_enqueue_script( 'comment-reply' ); } ?>
<?php  wp_head(); ?>
<?php $theme->hook('head'); ?>

</head>

All I'm hoping to do is add the calendar "events" to the Wordpress front page.

Wordpress sits at http://mydomain.com
SMF sits at http://mydomain.com/forums
Regards
Gavin Chatt
Austeam Founder
http://austeamracing.com.au

Kindred

IIRC, WordPress and SMF have some conflicting variable names -- so loading SSI within wordpress is an iffy proposition...

but you would add the SSI declaration and the function call within a php block/widget
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Gavin Chatt

Regards
Gavin Chatt
Austeam Founder
http://austeamracing.com.au

internets

How can I displaying wordpress content on my smf pages ? Any help?  :-\

Kindred

Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Exo_kg

Quote from: Kindred on March 06, 2014, 08:08:38 PM
but you would add the SSI declaration and the function call within a php block/widget

Could you suggest how to do it? I need edit SSI.php or only my php code in widget? Thanks

Kindred

well, I have already stated that it is an iffy proposition to begin with.

If you don't even know how SSI works, then I suggest not trying it until you have a better understanding of coding....

The first place you can start looking is in our very own WIKI/FAQ on how to use SSI.php
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

becometa

Quote from: Kindred on August 18, 2014, 05:57:43 PM
well, I have already stated that it is an iffy proposition to begin with.

If you don't even know how SSI works, then I suggest not trying it until you have a better understanding of coding....

The first place you can start looking is in our very own WIKI/FAQ on how to use SSI.php

So what steps are necessary to get it to work?
I don't mind that it would be an iffy thing to do. I as well as others just need the SSI inside wordpress.
Why should i limit myself and suffer using simpleportal/ezportal and such where I can have great CMS which WP definitely is connected with great forum software which SMF definitely is.

I've tested the steps that OP have suggested and on localhost environment for some unspecified amount of time IT WAS WORKING. Now it does not.

shinglis

Just to add I found this very useful and got working very quickly except the Wordpress plugin mentioned is no longer available.
QuoteWhat you Need
Wordpress Plugin:  ExecPHP ->
Plugin Version I used is 4.8

But I used this one instead :
PHP code Widget


Taken a few days effort reading all the forums / searching but happy to get resolved and can get on with some integration.

shinglis

QuoteJust to add I found this very useful and got working very quickly except the Wordpress plugin mentioned is no longer available.
Quote
What you Need
Wordpress Plugin:  ExecPHP ->
Plugin Version I used is 4.8

But I used this one instead :
PHP code Widget


Taken a few days effort reading all the forums / searching but happy to get resolved and can get on with some integration.

Right forget all that now found a version called : Shortcode Exec PHP;
which enable code to insert in posts, pages, widgets; just about anyway on your wordpress site.
added the require statement to header.php and everything great..

Gavin Chatt

Got this working on my site and love it however I'm not smart enough to know how to code and was hoping someone might know what I need to use to have upcom'n events show for a set period for example, maybe the next 30 days for example.

Right now I'm using Todays Events
<?php ssi_todaysEvents(); ?>
Regards
Gavin Chatt
Austeam Founder
http://austeamracing.com.au

JBlaze

You can use ssi_recentEvents() which will show x number of upcoming events. There's no way to do a custom date range without modifying the function and queries.

Show the next 15 upcoming events:
<?php ssi_recentEvents(15); ?>
Jason Clemons
Former Team Member 2009 - 2012

Gavin Chatt

Hi zilladotexe  :)

Have added that to the site but still not seeing it show up, also tried a (+15) just in case beeding to look forward but no joys, thanks tho.
Regards
Gavin Chatt
Austeam Founder
http://austeamracing.com.au

Advertisement: