osCommerce-freelancers
osCommerce Support Tickets separatorForum Home separatorUserCP separatorRegister separatorMemberlist separatorCalendar separator separatorFAQ
  
Go Back   osCommerce-Freelancers > archive > General Discussion > Contribution Support
User Name
Password
Reply
 
Thread Tools Display Modes

[CONTRIBUTION] Ultimate SEO URLs v2.1
Old 06-07-2005, 02:12 AM   #1
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default [CONTRIBUTION] Ultimate SEO URLs v2.1

First, welcome to the board.

Let's start the support...

Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 04:36 AM   #2
panzz
Member
 
panzz is Offline:
Join Date: Feb 2005
Location: Germany
Posts: 26 panzz is on a distinguished road
Send a message via ICQ to panzz
Default

Hi Bobby,

great to have your support back.

Have installed the new SEO URL and get an fatal error:

Fatal error: Call to a member function on a non-object in /homepages/14/d13488967/htdocs/includes/functions/html_output.php on line 19

Line 19 is: return $seo_urls->href_link($page, $parameters, $connection, $add_session_id);
}

Can you help me?

Greets,
panzz
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 04:42 AM   #3
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default

Fatal error: Call to a member function on a non-object

This means that the function is being called and the class has not been initialized. Make sure the code in application_top.php has been saved. It should look like this:
Code:

                                          
// include the language translations require(DIR_WS_LANGUAGES . $language . '.php'); // Ultimate SEO URLs v2.1 include_once(DIR_WS_CLASSES . 'seo.class.php'); $seo_urls = new SEO_URL($languages_id);

                                        


Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 04:47 AM   #4
panzz
Member
 
panzz is Offline:
Join Date: Feb 2005
Location: Germany
Posts: 26 panzz is on a distinguished road
Send a message via ICQ to panzz
Default

The Code is surley saved, here my application_top attached.

Greets,
panzz
Attached Files
File Type: txt application_top.txt (25.9 KB, 23 views)
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 04:55 AM   #5
misa
Member
 
misa is Offline:
Join Date: Jun 2005
Location: Alkmaar-Holland
Posts: 8 misa is on a distinguished road
Send a message via MSN to misa
Default

Ok Bobby,

First of all thanks for supporting us here.

I have installed both the new contributions without any errors now but wanted to ask you if you could have a quick look at my site if it's ok.

www.bruinenfit.nl

Thanks
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 05:10 AM   #6
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default

Quote:
Originally Posted by panzz
The Code is surley saved, here my application_top attached.

Greets,
panzz

Your application_top.php looks fine...

Setup FTP access for me and PM me the details. I'll take a look at your code and get you fixed up.

Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 05:10 AM   #7
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default

Quote:
Originally Posted by misa
Ok Bobby,

First of all thanks for supporting us here.

I have installed both the new contributions without any errors now but wanted to ask you if you could have a quick look at my site if it's ok.

www.bruinenfit.nl

Thanks

Your site looks fine...

Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 05:16 AM   #8
nameht
Member
 
nameht is Offline:
Join Date: Mar 2005
Posts: 8 nameht is on a distinguished road
Default

installation went fine for 2.1 but get the following error msg when in admin side for seo urls

Code:

                                          
Warning: call_user_func(tep_reset_cache_data_seo_urls): First argument is expected to be a valid callback in /homepages/9/****/htdocs/****/catalog/admin/includes/functions/general.php on line 1305

                                        
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 05:24 AM   #9
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default

Quote:
Originally Posted by nameht
installation went fine for 2.1 but get the following error msg when in admin side for seo urls

Code:

                                                    
Warning: call_user_func(tep_reset_cache_data_seo_urls): First argument is expected to be a valid callback in /homepages/9/****/htdocs/****/catalog/admin/includes/functions/general.php on line 1305

                                                  

Did you complete step #5 of the installation?

Ultimate SEO URLs online documentation

Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 05:28 AM   #10
nameht
Member
 
nameht is Offline:
Join Date: Mar 2005
Posts: 8 nameht is on a distinguished road
Default

oh im so dumb thought i was usign v 2.0 already so skipped that step...but turns out i was usin v1.4

thanks
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 05:34 AM   #11
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default

no problem...at least now you're ready to start upgrading to the next stable releases

The good thing is that the upgrade from here on out is as simple as overwriting the class file.

How many contributions can say that? To upgrade the whole code base just overwrite the file...

Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 05:39 AM   #12
nameht
Member
 
nameht is Offline:
Join Date: Mar 2005
Posts: 8 nameht is on a distinguished road
Default

indeed is true i wish all contributions could be as well documented, organized, and easy to install as yours (not to mention so usefull)

btw you on IM atm? would like to speak to you briefly it all possible
  Reply With Quote Muli-quote with this post

error
Old 06-07-2005, 05:56 AM   #13
hansmignon
Member
 
hansmignon is Offline:
Join Date: Jun 2005
Posts: 16 hansmignon is on a distinguished road
Default error

Hello Bobby,

I have the same problem as panzz.

Call to a member function on a non-object in /var/www/html/includes/functions/html_output.php on line 8

return $seo_urls->href_link($page, $parameters, $connection, $add_session_id);
}

Did you find a solution for this ?

Thanks

Hans
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 06:14 AM   #14
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default

I did...but the solution is very server intensive. Panzz is using STS template system and for some reason it's not allowing the global declaration of the $seo_urls object...which is critical for operation.

Use this code for your html_output.php / tep_href_link() function:
Code:

                                          
//// // Ultimate SEO URLs v2.1 // The HTML href link wrapper function function tep_href_link($page = '', $parameters = '', $connection = 'NONSSL', $add_session_id = true, $search_engine_safe = true) { global $seo_urls; if ( !is_object('seo_urls') ){ global $languages_id; include_once(DIR_WS_CLASSES . 'seo.class.php'); $seo_urls = new SEO_URL($languages_id); } return $seo_urls->href_link($page, $parameters, $connection, $add_session_id); }

                                        


Be sure to check back often since I'll be looking for the better solution for this problem...

Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 06:21 AM   #15
hansmignon
Member
 
hansmignon is Offline:
Join Date: Jun 2005
Posts: 16 hansmignon is on a distinguished road
Default

Thanks Bobby,

It is working but now he is generating another error:

Warning: eregi(): Invalid preceding regular expression in /var/www/html/includes/classes/seo.class.php on line 699

Warning: eregi(): Invalid preceding regular expression in /var/www/html/includes/classes/seo.class.php on line 699

Warning: eregi(): Invalid preceding regular expression in /var/www/html/includes/classes/seo.class.php on line 699

Warning: eregi(): Invalid preceding regular expression in /var/www/html/includes/classes/seo.class.php on line 699

Sorry to disturb you again.


Hans
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 06:33 AM   #16
panzz
Member
 
panzz is Offline:
Join Date: Feb 2005
Location: Germany
Posts: 26 panzz is on a distinguished road
Send a message via ICQ to panzz
Default

Bobby,

have done #6 and configure admin.

I think site loads slower than before.

Also the redirect function don't work now:

http://www.trendfabrik.com/product_...?products_id=93

Thanks,
panzz
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 06:34 AM   #17
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default

What is the code above and below line 699? Your file is a bit different than mine now since I've been adding code...

Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 06:36 AM   #18
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default

The site does indeed run slower...that is because the seo_urls object is being initialized on each call to tep_href_link().

The problem is that for some reason it is not allowing the global declaration of the seo_urls object from application_top.php. The reason why is not know to me at this time. Rest assured that once I find an answer it will be applied to you site first.

As for the redirect: you are running PHP in CGI mode which throws off the URLs a bit. I'll look into it tomorrow...

Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 06:38 AM   #19
hansmignon
Member
 
hansmignon is Offline:
Join Date: Jun 2005
Posts: 16 hansmignon is on a distinguished road
Default

This is the code from lin 647 till 759

Thanks,

Hans

* Function to check if the products_id contains an attribute
* @author Bobby Easland
* @version 1.0
* @param integer $pID
* @return boolean
*/
function is_attribute_string($pID){
699 if ( eregi('{', $pID) ){
return true;
} else {
return false;
}
} # end function
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 06:45 AM   #20
panzz
Member
 
panzz is Offline:
Join Date: Feb 2005
Location: Germany
Posts: 26 panzz is on a distinguished road
Send a message via ICQ to panzz
Default

Quote:
Rest assured that once I find an answer it will be applied to you site first.


Quote:
As for the redirect: you are running PHP in CGI mode which throws off the URLs a bit. I'll look into it tomorrow...


Sounds perfect, looking fwd for your great support.

Thanks!

Best,
panzz
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 06:51 AM   #21
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default

Quote:
Originally Posted by hansmignon
This is the code from lin 647 till 759

Thanks,

Hans

* Function to check if the products_id contains an attribute
* @author Bobby Easland
* @version 1.0
* @param integer $pID
* @return boolean
*/
function is_attribute_string($pID){
699 if ( eregi('{', $pID) ){
return true;
} else {
return false;
}
} # end function

Try this code for that function and tell me if it works for you:
Code:

                                          
function is_attribute_string($pID){ if (is_numeric(strpos($pID, '{'))){ return true; } else { return false; } } # end function

                                        


EDIT: forgot a closing bracket

Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 07:34 AM   #22
hansmignon
Member
 
hansmignon is Offline:
Join Date: Jun 2005
Posts: 16 hansmignon is on a distinguished road
Default

Hello Bobby,

It is working but now he has a problem with line 1329.

function need_redirect(){
1329 if ( ereg("{|}", $this->real_uri) ){ $this->need_redirect = false;
} else {
foreach( $this->reg_anchors as $param => $value){
$pattern[] = $param;
}

About the oscommerce problem with Herald. Will you start your own oscommere project ?

Thanks,

Hans
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 07:37 AM   #23
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default

Try this function:
Code:

                                          
function need_redirect(){ if ( is_numeric(strpos($this->real_uri, '{')) ){ $this->need_redirect = false; } else { foreach( $this->reg_anchors as $param => $value){ $pattern[] = $param; } $this->uri != $this->real_uri ? $this->need_redirect = false : eregi("(cName|pName|mName)", $this->uri) ? $this->attributes['SEO_REWRITE_TYPE'] != 'cName' ? $this->need_redirect = true : $this->need_redirect = false : eregi("(".implode('|', $pattern).")", $this->uri) ? $this->need_redirect = true : $this->need_redirect = false; } } # end function set_seopage

                                        


Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 08:06 AM   #24
hansmignon
Member
 
hansmignon is Offline:
Join Date: Jun 2005
Posts: 16 hansmignon is on a distinguished road
Default

Yes it is working.

Thank you verry much Bobby.

Will you still work with oscommerce ?

Thx,

Hans
  Reply With Quote Muli-quote with this post

Old 06-07-2005, 08:30 AM   #25
Chemo
Putting Keyboard to Code...
 
Chemo's Avatar
 
Chemo is Offline:
Join Date: Feb 2005
Location: /usa/kentucky/richmond/
Posts: 391 Chemo is on a distinguished road
Send a message via AIM to Chemo Send a message via MSN to Chemo Send a message via Yahoo to Chemo
Default

Quote:
Originally Posted by hansmignon
Yes it is working.

Thank you verry much Bobby.

Will you still work with oscommerce ?

Thx,

Hans

That is up to Harald and the project team...

Bobby
__________________
For immediate help call (859) 514-5395
(between 8 AM - 4 PM EST)


Tools
Chemo's Search Engine Spider Simulator
Chemo's PHP Code Pastebin


Sites
My osCommerce Blog
osCommerce Freelancers
osCommerce Development Server
eCommerce Directory
BDC Concepts Directory
  Reply With Quote Muli-quote with this post
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Ultimate SEO URLs for Zencart birdnerd SEO Strategy 4 08-17-2006 03:43 AM



All times are GMT -4. The time now is 10:40 AM.