Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Modules
Author Message
candy
Worker
Worker



Joined: Dec 21, 2004
Posts: 225
Location: Kansas City metro

PostPosted: Wed Jul 05, 2006 6:26 pm Reply with quote

is there a way i can have a link in the Web Links module appear in more than one category? when i go to approve a listing that has already been approved for another category, i get the following error:

Quote:
ERROR: This URL is already listed in the Database!



thanks!
 
View user's profile Send private message
kguske
Site Admin



Joined: Jun 04, 2004
Posts: 6437

PostPosted: Wed Jul 05, 2006 8:12 pm Reply with quote

That's a check to prevent duplicate links (some people would submit that hoping it would help their search engine rankings). You could remove that edit from the code...

_________________
I search, therefore I exist...
Only registered users can see links on this board! Get registered or login!
 
View user's profile Send private message
candy







PostPosted: Wed Jul 05, 2006 8:26 pm Reply with quote

any idea on how to go about that? Question
 
kguske







PostPosted: Wed Jul 05, 2006 8:29 pm Reply with quote

If you get the error message on the submit and want to allow it, look in the modules/Weblinks/index.php file and comment out the lines that perform the edit (you should be able to find the error message defined in a variable in the modules/Weblinks/language/lang-xxx.php file).

If you want to bypass the error message in the admin function, look at the modules/Weblinks/admin/index.php file for a similar error message.
 
candy







PostPosted: Wed Jul 05, 2006 8:42 pm Reply with quote

i want it to LET me approve a link that is already part of the database. when i go comment the above out all it does is not show the error. it is still not letting me add/approve the web link that was submitted. any ideas?
 
kguske







PostPosted: Wed Jul 05, 2006 8:49 pm Reply with quote

Instead of getting the error message, what happens?
 
candy







PostPosted: Wed Jul 05, 2006 8:54 pm Reply with quote

it shows "_ERRORURLEXIST" but doesn't show the text of "The URL already exists in the database".

This happens when i click "add" button the submitted URL in the admin panel.

How can i structure the Web Links module so that it doesn't check to see whether or not the URL is already in the database? is this in the language file too?
 
kguske







PostPosted: Wed Jul 05, 2006 9:01 pm Reply with quote

Sounds like you commented out the language definition, but not the edit in modules/Weblinks/admin/index.php
 
candy







PostPosted: Wed Jul 05, 2006 9:08 pm Reply with quote

weird...i don't have an admin folder in my public_html/modules/Weblinks folder!

anywhere else it'd be?
 
fkelly
Former Moderator in Good Standing



Joined: Aug 30, 2005
Posts: 3312
Location: near Albany NY

PostPosted: Wed Jul 05, 2006 9:08 pm Reply with quote

Look in /modules/web_links/index.php. There you will find the function add. It checks to see if the url already exists and if so gives the message you see.

You could program web_links to circumvent this check. I couldn't guarantee whether this might cause problems elsewhere so you'd be advised to test it somewhere where users wouldn't be affected if it goes haywire.
 
View user's profile Send private message Visit poster's website
kguske







PostPosted: Wed Jul 05, 2006 9:11 pm Reply with quote

If you're using PHP-Nuke prior to 7.5, it could be in the admin/modules/news.php or something like that.
 
candy







PostPosted: Wed Jul 05, 2006 9:14 pm Reply with quote

i don't have a news.php under my admin/modules folder. Bang Head
 
kguske







PostPosted: Thu Jul 06, 2006 4:50 am Reply with quote

What version / distribution of PHP-Nuke are you using?

I gave you the wrong file name - sorry! It's admin/modules/links.php (I had news on the brain...).
 
candy







PostPosted: Thu Jul 06, 2006 10:55 am Reply with quote

i think i am using 7.4 but don't know for sure....how can i tell?
 
kguske







PostPosted: Thu Jul 06, 2006 2:41 pm Reply with quote

If you see admin/modules/links.php, you'll know it's not 7.5 or higher.
 
candy







PostPosted: Thu Jul 06, 2006 3:01 pm Reply with quote

yep, i do see it but don't know what to edit in links.php
 
kguske







PostPosted: Thu Jul 06, 2006 4:02 pm Reply with quote

Look for the code that generates the error message, and comment it out.
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Modules

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©