SEFA Ignored Component Not ignored exactly

14 years 1 month ago #5575 by dezblanco
I've got a 3rd party component NOT meant to work with SEF Advanced so I set the component to ignored in the SEFA admin panel, but apparently, with SEFA enabled, the the 3rd party component is not able to get its SEF urls from Joomla.

not until SEF Advanced is disabled will the joomla SEF urls get produced for this component.

Any suggestions how this can be fixed?  This component is very important to our site and not using it would not be an option.

Regards,

Please Log in or Create an account to join the conversation.

14 years 1 month ago #5577 by Saka
Hello,

If you set ignore for particular component non-sef URLs are produced. To get standard Joomla SEF URLs you don't have to ignore the component, you should get them automatically if the component has router.php file.

Emir Sakic
www.sakic.net

Please Log in or Create an account to join the conversation.

14 years 1 month ago #5578 by dezblanco
You are absolutely right, but there is still something sliding through the cracks, because with this component, there is a save function for a form.  with SEF Advance disabled, the browser will go to the listing which has just been saved and display the information entered, with SEF Advanced enabled, the browser goes to a blank page - the page is still within our theme, but it looks like a blank "wrapper" page.

Please Log in or Create an account to join the conversation.

14 years 1 month ago #5614 by dezblanco
i'm still experiencing a problem with SEF Advance and the SuperEvents component.  With SEF Advance enabled, the SEvents component doesn't get the correct joomla sef urls.  Turn off Sef advance, and SuperEvents gets the correct joomla sef urls.

Emir, if you could please take look at the router.php file for superevents, and tell if you see something that could cause this, or perhaps you would have some other suggestion as to what could cause this.

Thanks
function supereventsBuildRoute( &$query )

{

       if(isset($query['redirect'])){

    		$redirect = $query['redirect'];

	     }elseif(isset($_REQUEST['redirect']) && strlen($_REQUEST['redirect'])>0){

		    $redirect = JRequest::getcmd('redirect');

	     }else{

		    $redirect="self";

	     }

       $db= JFactory::getDBO();

       $segments = array();

/*       if(isset($query['option']))

       {

                $segments[] = 'groups';

                unset( $query['option'] );

       }*/

       if(isset($query['task']))

       {

                $task = $query['task'];

                switch ($task) {

                  case 'bulls':

                    $task = 'discussions';

                  break;

                  case 'addbull':

                    $task = 'add_discussion';

                  break;

                }

                $segments[] = $task;

                unset( $query['task'] );

       }

       if(isset($query['view']))

       {

                $segments[] = $query['view'];

                unset( $query['view'] );

       }

       if(isset($query['catid']))

       {

                $db->setQuery("SELECT name FROM #__superevent_categories WHERE id=".$query['catid']);

                $group = $db->loadResult();

                $group = ereg_replace("-monoeisagwgiko-","'", $group);

                $group = ereg_replace("-diploeisagwgiko-",'"', $group);

                $group = str_replace(".",'_', $group);

                $segments[] = SE_url_encode($query['catid'].'_'.$group);

                unset( $query['catid'] );

       }

       if(isset($query['id']))

       {

              if (isset($redirect) && $redirect!='archive') {

                $db->setQuery("SELECT alias FROM #__superevents WHERE published=1 AND id=".$query['id']);

                $groupobj = $db->loadObject();

                if (!count($groupobj)) {

                    $db->setQuery("SELECT alias FROM #__superevents_archive WHERE published=1 AND id=".$query['id']);

                    $group = $db->loadResult();

                } else $group = $groupobj->alias;

              } else {

                  $db->setQuery("SELECT alias FROM #__superevents_archive WHERE published=1 AND id=".$query['id']);

                  $group = $db->loadResult();

                }

                /*$group = ereg_replace("-monoeisagwgiko-","'", $group);

                $group = ereg_replace("-diploeisagwgiko-",'"', $group);*/

                $group = str_replace("-",'_', $group);

                $group = SE_url_encode($group);                

                $segments[] = $group;

                unset( $query['id'] );

       }

       /*if(isset($query['redirect']))

       {

                $segments[] = 'backto:'.$query['redirect'];

                unset( $query['redirect'] );

       }*/

       return $segments;

}



function supereventsParseRoute($segments)

{

       $redirect = JRequest::getcmd('redirect');

       $db= JFactory::getDBO();

       $vars = array();



          $task = $segments[0];

                switch ($task) {

                  case 'discussions':

                    $task = 'bulls';

                  break;

                  case 'add_discussion':

                    $task = 'addbull';

                  break;

                }

       $vars['task'] = $task;

       $vars['view'] = $segments[1];

       

       //if ($vars['view']=="category" || strstr($segments[4],'backto')) {

       if ($vars['view']=="category" || isset($segments[3])) {

          if (isset($segments[2])) {

                $group = SE_url_decode($segments[2]);

                $group = explode('_', $group);

                /*$group = str_replace("_",'.', $group);

                $group = ereg_replace("'","-monoeisagwgiko-", $segments[2]);

                $group = ereg_replace('"',"-diploeisagwgiko-", $group);

                $db->setQuery("SELECT id FROM #__superevent_categories WHERE name='".$group."'");

                $group = $db->loadResult();*/

            $vars['catid'] = $group[0];

          }

          if (isset($segments[3])) {

                $group = SE_url_decode($segments[3]);

                $group = str_replace("_",'-', $group);

                /*$group = ereg_replace("'","-monoeisagwgiko-", $segments[3]);

                $group = ereg_replace('"',"-diploeisagwgiko-", $group);*/

              if ($redirect!='archive') {

                $db->setQuery("SELECT id FROM #__superevents WHERE published=1 AND alias='".$group."'");

                $groupobj = $db->loadObject();

                if (!count($groupobj)) {

                  $db->setQuery("SELECT id FROM #__superevents_archive WHERE published=1 AND alias='".$group."'");

                  $group = $db->loadResult();

                } else $group = $groupobj->id;

              } else {

                  $db->setQuery("SELECT id FROM #__superevents_archive WHERE published=1 AND alias='".$group."'");

                  $group = $db->loadResult();

                }

            $vars['id'] = $group;

          }

          //if (isset($segments[4])) $vars['redirect'] = str_replace('backto:','',$segments[4]);

      } else {

          if (isset($segments[2])) {

                $group = SE_url_decode($segments[2]);

                $group = str_replace("_",'-', $group);

                /*$group = ereg_replace("'","-monoeisagwgiko-", $segments[2]);

                $group = ereg_replace('"',"-diploeisagwgiko-", $group);*/

              if ($redirect!='archive') {

                $db->setQuery("SELECT id FROM #__superevents WHERE published=1 AND alias='".$group."'");

                $groupobj = $db->loadObject();

                if (!count($groupobj)) {

                  $db->setQuery("SELECT id FROM #__superevents_archive WHERE published=1 AND alias='".$group."'");

                  $group = $db->loadResult();

                } else $group = $groupobj->id;

              } else {

                  $db->setQuery("SELECT id FROM #__superevents_archive WHERE published=1 AND alias='".$group."'");

                  $group = $db->loadResult();

                }

            $vars['id'] = $group;

          }

          //if (isset($segments[3])) $vars['redirect'] = str_replace('backto:','',$segments[3]);

      }

      if(strlen($redirect)>1) $vars['redirect']=$redirect;    



      return $vars;

}



    function SE_url_encode($string){

        return urlencode(utf8_encode($string));

    }

   

    function SE_url_decode($string){

        return utf8_decode(urldecode($string));

    }

?>

Please Log in or Create an account to join the conversation.

14 years 1 month ago #5615 by Saka
Hard to tell like this. If you send me the admin password and FTP I can login and test. Make sure you run the latest version of SEF Advance first.

Emir Sakic
www.sakic.net

Please Log in or Create an account to join the conversation.

14 years 1 month ago #5619 by dezblanco
Emir, I forwarded the necessary information to you via email yesterday and have installed the latest version of SEFA.  The problem still exists with the new version as well.

Please Log in or Create an account to join the conversation.

About us

We provide high quality Joomla components created by a co-founder and original core developer of Joomla. For over a decade, our products have been used by more than 20.000 webmasters around the world.

Stay in touch