�V�
Search: �
  • Home
  • Help
  • Search
  • Login
  • Register
Welcome, Guest. Please login or register.
Did you miss your activation email?
September 03, 2010, 04:40:21 PM

Login with username, password and session length
collapse collapse
* User Info
 
 
Welcome, Guest. Please login or register.
Did you miss your activation email?

* Who's Online
  • Dot Guests: 7
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.

* News from Joomla
  • post Joomla 1.6 Beta 8 Now Available
  • The Joomla Project is proud to announce the immedi...
  • post Joomla 1.6 Beta 7 Now Available
  • The Joomla Project is proud to announce the immedi...
  • post Joomla 1.6 Beta 6 Now Available
  • The Joomla Project is proud to announce the immedi...

Welcome to Locutus web services forum!

Locutus Web Services�>�General Category�>�Joomla�>�JSMF bridge�>�JSMF FAQ
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Go Down Print
Author Topic: JSMF FAQ  (Read 1404 times)
locutus
Administrator
Hero Member
*****
Offline Offline

Posts: 95


The sky ain't the limit


WWW
JSMF FAQ
« on: August 15, 2008, 11:11:58 PM »

Q: Where can I download the latest JSMF component, modules and plugins?
A: You can find them listed together here: http://locutusweb.asw15.org/index.php/topic,10.new.html

Q: I have Joomla! 1.0.15 which version of JSMF do I need?
A: You need version JSMF 2.0.2.1 for the Joomla versions 1.0.13, 1.0.14 and 1.0.15. Also this bridge will only work with SMF version 1.1.x

Q: I have Joomla! 1.5.x which version of JSMF do I need?
A: JSMF is not compatible with Joomla 1.5.x. Development has stopped, so it won't be compatible in the future.

Q: I have SMF 2.0 (beta/RC) which version of JSMF do I need?
A: JSMF is not compatible with SMF 2.0 (beta/RC). Development has stopped, so it won't be compatible in the future.

Q: I have installed JSMF but it doesn't work.
A: First uninstall JSMF, next download the manual (for the download see above). Read the manual and make sure you understand every step. Then at last install JSMF step by step according to the manual. If you are still having problems, you are free to post in the forum.

Q: before I upgrade JSMF, I should back it up; how do I do that? (And howto restore)
A:

    * note your settings JSMF in the JSMF configuration panel
    * set Joomla off line in the configuration
    * set SMF off line in the SMF administration
    * BACK UP ALL YOUR FILES!
    * BACK UP YOUR DATABASE!
    * In the installation tab of JSMF unpatch Joomla
    * In the installation tab of JSMF unpatch SMF
    * Uninstall JSMF
    * Upgrade Joomla 1.0.x according to the instructions
    * Upgrade SMF 1.1.x according to the instructions
    * Verify Joomla and SMF are working fine stand alone
    * Install the latest JSMF
    * In the installation tab of JSMF patch Joomla
    * In the installation tab of JSMF patch SMF
    * Configure JSMF like it was
    * set Joomla on line in the configuration
    * set SMF on line in the SMF administration

(BTW did I mention to backup?   Tongue)

Q: I have upgraded Joomla! (to 1.0.15), now I can't log in anymore.
A: You need to upgrade to JSMF 2.0.2.1

Q: I can't see posts with more than one page or topics are not visible (blank page) for admins.
A: This problem is due to an error in PHP 5.2.5. First check your PHP version via: Administration > System > System info. If you have  PHP 5.2.5 then you have three options:

Option 1:
Lowering your PHP version by adding the next line to your .htaccess. (some hosts won't allow this)

Code:
AddHandler application/x-httpd-php51 .php

Option2:
Replace some code in smf.class.php in /components/com_smf.
Find this code:
Code:
$regex = array('/<!DOCTYPE.*<body>/smi', '/<\/body>/i', '/<\/html>/i');
$buffer = preg_replace($regex, array('', '', ''), $buffer);
unset($matches, $keywords, $css, $search, $replace, $headers, $regex);
and replace it with:

Code:
//Regex broken with PHP 5.2.5           
//$regex = array('/<!DOCTYPE.*<body>/smi', '/<\/body>/i', '/<\/html>/i');
//$buffer = preg_replace($regex, array('', '', ''), $buffer);
//unset($matches, $keywords, $css, $search, $replace, $headers, $regex);
$needle = '<body>';
$buffer = strstr($buffer, $needle);
$buffer = substr($buffer, strlen($needle));
$regex = array('/<\/body>/i', '/<\/html>/i');
$buffer = preg_replace($regex, array('', ''), $buffer);
unset($matches, $keywords, $css, $search, $replace, $headers, $regex, $needle);
Option3:
Patch some code in smf.class.php in /components/com_smf. At the end of the file add this function:

Code:
function t_get_content($src_for1, $src_for2, $src_in){
  $ret='';
  $pos1=stripos($src_in, $src_for1);
  $pos2=stripos($src_in, $src_for2);


  if ($pos1 and $pos2 and ($pos1 <= $pos2)){
    $pos1 = $pos1 + strlen($src_for1);
    $ret = substr($src_in, $pos1, $pos2-$pos1);
  }
  return $ret;
}

Comment and add this:

Code:
// -- start comment--
//                $regex = '/<head>.*<\/head>/smi';
//                preg_match($regex, $buffer, $matches);

//                 if (!empty($matches))
//                  {
//                   $headers = $matches[0];
//                  }
// -- end comment--

                $headers = t_get_content('<head>', '</head>', $buffer);


and a few lines bellow:

Code:
// -- start comment--
//            $regex = array('/<!DOCTYPE.*<body>/smi', '/<\/body>/i', '/<\/html>/i');

//            $buffer = preg_replace($regex, array('', '', ''), $buffer);
// -- end comment--

             $buffer = t_get_content('<body>','</body>',$buffer);


IMPORTANT: Caching must be disabled in JSMF bridge. If you have CSS problems after this fix ; please see next Q&A.

Q: I am having serious CSS trouble, what to do?
A: add this to SMF in the head section of index_template.php
Code:

Code:
if (!empty($_REQUEST['option'])){

echo '<link rel="stylesheet" type="text/css" href="', $settings['theme_url'], '/smfstyle.css?fin11" />

<link rel="stylesheet" type="text/css" href="', $settings['default_theme_url'], '/print.css?fin11" media="print" />';

} else { echo '

<link rel="stylesheet" type="text/css" href="', $settings['theme_url'], '/style.css?fin11" />'; }


What that does is checks to see if SMF is wrapped or not. If it is it uses style.css if not it uses smfstyle.css
So what you need to do is create 2 css sheets.

One that has everything (smfstyle.css) and one that has been stripped of all a. elements. and main link styles (not the menu) and some more depending on Joomla.

Q: After SMF registration SMF login fails
A: This is due to the fact that because of the way SMF handles variables we can't synchronize immediately.  You must first login through a Joomla based login(JSMF login, CB login(with plugin), or default Joomla login) or login twice.  Why twice?  After the first failure we are able to trigger a synchronization event so the second login should succeed.

Q: Each time I start a post (PM, Topic, Message....) in the top of the page above the header appears "\n\t\t\n\t "
A: For the "\n\t\t\n\t " problem is a special patch created. You can download it here: http://h1.ripway.com/joomlahacks/com_smf_2_0_2_1a.zip

Q: I want to adapt my SMF theme to my existing Joomla template, how do I do that?
A: Over here is a very nice tutorial: http://www.simplemachines.org/community/index.php?topic=145838.0
« Last Edit: August 20, 2008, 11:32:43 PM by locutus » Logged

Conquer the skies with the Gelderse Soaring Club
Pages: [1] Go Up Print
« previous next »
Jump to:  


* Recent Topics
topic My distro stopper: Lubuntu!
[Linux]
locutus
August 31, 2010, 04:12:41 AM

* News from SMF
  • post Twitter background contest!
  • Hello Community,

    The SimpleMachines Te...
  • post A reminder to update your email and passwords
  • Hello community,

        The Simple Machin...
  • post SMF 2.0 Release Candidate 3 is out!
  • Hello all,

    We are pleased to announce ...

* Top Poster
locutus locutus
95 Posts
baijianpeng baijianpeng
26 Posts
aim1986
10 Posts
GJSchaller GJSchaller
6 Posts
Neeraj123
5 Posts

Powered by SMF 1.1.11 | SMF © 2006-2008, Simple Machines LLC
SimplePortal 2.3.1 © 2008-2009, SimplePortal

Scribbles2 design by Bloc | XHTML | CSS
Page created in 1.67 seconds with 26 queries.
Loading...