 | [Solved] Music Search Mod |  |
Posted: 05/09/2007 2:07 PM |
|
|
|
|
|
| Citation |
| Posts |
1332 |
| Word Cnt. |
86,126 |
| BDay |
Feb 11 |
| Sign |
Aquarius |
| Sex |
 |
|
|
|
Joined: Mar 31, 2007
Local time: 10:34 PM
Location: Birmingham, UK.
|

|
|
|
|
 |
Hey,
I'm having a few probs with this mod, well, first of I had to correct the install code so that it would work with EM, after changing the install text many times I finally got it to install. Though when I checked I noticed the two files never copied so I had to copy them manually, weird though because EM said it copied the files. After I’d done this though I noticed that when searching the word 'test' using this page http://www.djpassions.com/music.php it doesn't show any results for test. I also tried http://www.djpassions.com/music_list.php but I get this error
| Code:
|
General Error
Could not query search songs information
DEBUG MODE
SQL Error : 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '-1' at line 10
SELECT s.song_id, s.song_title, s.song_desc, s.song_singer, s.song_user_id, s.song_user_ip, s.song_username, s.song_time, s.song_cat_id, s.song_view_count, u.user_id, u.username, r.rate_song_id, AVG(r.rate_point) AS rating, COUNT(DISTINCT c.comment_id) AS comments, MAX(c.comment_id) as new_comment FROM phpbb_music AS s LEFT JOIN phpbb_users AS u ON s.song_user_id = u.user_id LEFT JOIN phpbb_music_cat AS ct ON s.song_cat_id = ct.cat_id LEFT JOIN phpbb_music_rate AS r ON s.song_id = r.rate_song_id LEFT JOIN phpbb_music_comment AS c ON s.song_id = c.comment_song_id WHERE s.song_title LIKE 'test' GROUP BY s.song_id ORDER BY s.song_time DESC LIMIT -1
Line : 111
File : music_list.php
|
Also why can you search using music.php and music_list.php? They both do the same thing  |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Music Search Mod |  |
Posted: 05/09/2007 2:34 PM |
|
|
|
|
|
| Citation |
| Posts |
407 |
| Word Cnt. |
10,993 |
| BDay |
May 28 |
| Sign |
Gemini |
| Sex |
 |
|
|
|
Joined: Feb 25, 2007
Local time: 9:34 PM
Location: SE England
|

|
|
|
|
 |
Looks to me like this was missing from the end of the MySQL Statement on install:
Just a guess.
- Poomie |
|
|
 |
 |
| Back to Top |
|
|
 | Re: Music Search Mod |  |
Posted: 05/09/2007 2:50 PM |
|
|
|
|
|
| Site Admin |
| Posts |
30757 |
| Word Cnt. |
2,628,690 |
| BDay |
Jul 28 |
| Sign |
Leo |
| Sex |
 |
|
|
|
Joined: Sep 25, 2004
Local time: 5:34 PM
Location: St Pete, FL
|

|
|
|
|
 |
I'm really not sure that the LIMIT -1 parameter is valid. The LIMIT function gives a range of records to display, so usually the format is LIMIT x, y. The x would represent the record number to start with and y would represent the number of records to display. So LIMIT 0, 10 would mean to display 10 records beginning with the first record in the result set. There would not be a -1 record...
So try this:
OPEN
music_list.php
FIND
REPLACE WITH
You would need to do this in 3 places in the music_list.php file...
 |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Music Search Mod |  |
Posted: 05/09/2007 3:13 PM |
|
|
|
|
|
| Citation |
| Posts |
1332 |
| Word Cnt. |
86,126 |
| BDay |
Feb 11 |
| Sign |
Aquarius |
| Sex |
 |
|
|
|
Joined: Mar 31, 2007
Local time: 10:34 PM
Location: Birmingham, UK.
|

|
|
|
|
 |
I replaced
with
but when searching the word test using the search box on this page http://www.djpassions.com/music.php no results appear. It should do though as I created a test in the trance / dance section
The results do appear on the music_list.php though now I replaced the one code with the other. I’m guessing the search box on the music.php page shouldn’t be there…
 |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Music Search Mod |  |
Posted: 05/09/2007 3:29 PM |
|
|
|
|
|
| Citation |
| Posts |
407 |
| Word Cnt. |
10,993 |
| BDay |
May 28 |
| Sign |
Gemini |
| Sex |
 |
|
|
|
Joined: Feb 25, 2007
Local time: 9:34 PM
Location: SE England
|

|
|
|
|
 |
Aaah, thought I was wrong.
Hope you get it working how you want it to
*Poomerio takes notes
- Poomie
EDIT: I must have mis-read the question.
Just ignore me - I'm having an off day today.
Please, continue  |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Music Search Mod |  |
Posted: 05/09/2007 3:48 PM |
|
|
|
|
|
| Citation |
| Posts |
1332 |
| Word Cnt. |
86,126 |
| BDay |
Feb 11 |
| Sign |
Aquarius |
| Sex |
 |
|
|
|
Joined: Mar 31, 2007
Local time: 10:34 PM
Location: Birmingham, UK.
|

|
|
|
|
 |
You were very close Poomerio  |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Music Search Mod |  |
Posted: 05/09/2007 4:34 PM |
|
|
|
|
|
| Citation |
| Posts |
1332 |
| Word Cnt. |
86,126 |
| BDay |
Feb 11 |
| Sign |
Aquarius |
| Sex |
 |
|
|
|
Joined: Mar 31, 2007
Local time: 10:34 PM
Location: Birmingham, UK.
|

|
|
|
|
 |
Very strange  |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Music Search Mod |  |
Posted: 05/09/2007 6:51 PM |
|
|
|
|
|
| Citation |
| Posts |
1332 |
| Word Cnt. |
86,126 |
| BDay |
Feb 11 |
| Sign |
Aquarius |
| Sex |
 |
|
|
|
Joined: Mar 31, 2007
Local time: 10:34 PM
Location: Birmingham, UK.
|

|
|
|
|
 |
how these mods pass validation is beyond me  |
|
|
 |
 |
| Back to Top |
|
|
 | Re: Music Search Mod |  |
Posted: 05/10/2007 1:46 AM |
|
|
|
|
|
| Site Admin |
| Posts |
30757 |
| Word Cnt. |
2,628,690 |
| BDay |
Jul 28 |
| Sign |
Leo |
| Sex |
 |
|
|
|
Joined: Sep 25, 2004
Local time: 5:34 PM
Location: St Pete, FL
|

|
|
|
|
 |
Before I do a search, I get this:
The search doesn't work in Opera or IE but it does in Firefox:
So it's another browser specific problem with the MOD...
I can no longer log into your djpassions FTP server, so I can't even get a copy of the MOD that you installed for this or be able to troubleshoot the code. If you want me to take a closer look, send me a PM with the FTP login details so that I can correct what I have. Otherwise, I will need a link to the MOD topic and/or download...
 |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Music Search Mod |  |
Posted: 05/10/2007 4:35 AM |
|
|
|
|
|
| Citation |
| Posts |
1332 |
| Word Cnt. |
86,126 |
| BDay |
Feb 11 |
| Sign |
Aquarius |
| Sex |
 |
|
|
|
Joined: Mar 31, 2007
Local time: 10:34 PM
Location: Birmingham, UK.
|

|
|
|
|
 |
|
|
 |
 |
| Back to Top |
|
|
 | Information |  |
|