|
|
 |
|
October 20th, 2007, 08:29 AM
|
#21
|
|
WebForumz Member
Join Date: Oct 2007
Location: room
Age: 19
Posts: 77
Thanks: 0
Thanked 1 Time in 1 Post
Rep Altering Power: 0
|
Re: Radio Button Response! :(
good point....
wwwhhhheeeyyyy it woorrkkkss...ish....
umm.. ill pm you the new beta test link.. all the google'S work, but not the wiki's etc.. no error, just doesnt redirect to search, just blank.
man i am anoying you =D
|
|
|
October 22nd, 2007, 08:47 AM
|
#22
|
|
Highly Reputable Member
SuperMember
Join Date: Sep 2007
Location: Australia
Age: 25
Posts: 956
Thanks: 0
Thanked 0 Times in 0 Posts
|
Re: Radio Button Response! :(
It would appear something has gone wrong in your code somewhere as the youTube options are going to google. ;(
|
|
|
October 24th, 2007, 07:44 AM
|
#23
|
|
WebForumz Member
Join Date: Oct 2007
Location: room
Age: 19
Posts: 77
Thanks: 0
Thanked 1 Time in 1 Post
Rep Altering Power: 0
|
Re: Radio Button Response! :(
do you have msn or icq or something? :P this is getting queit hard to do over a forum, and we will past the fixed code here after?
|
|
|
October 24th, 2007, 08:53 AM
|
#24
|
|
Highly Reputable Member
SuperMember
Join Date: Sep 2007
Location: Australia
Age: 25
Posts: 956
Thanks: 0
Thanked 0 Times in 0 Posts
|
Re: Radio Button Response! :(
Okay I have cleaned upi your code a little and it should work.
Just keep the $headerSettings['indexes'] in lower case and be mindful of the swicth syntax and all should be well.
Code:
<?php
$headerSettings = array();
// for the sake of simplicity, keep all of the index values in lower case
// eg. $header['myname'] as opposed to $header['myName']
$headerSettings['mp3s'] = ' intitle:"index.of" "parent directory" "size" "last modified" "description" [snd] (mp4|mp3|avi|flac|aac|ape|ogg) -inurl:(jsp|php|html|aspx|htm|cf|shtml|lyrics-realm|mp3-collection) -site:.info';
$headerSettings['albums'] = ' site:zshare.net OR site:rapidshare.net OR site:rapidshare.com OR site:megaupload.com OR site:updownloadserver.de OR site:sharebigfile.com OR site:upload.sc OR site:bigfileupload.com OR site:upload2.net';
$headerSettings['torrents'] = ' site:thepiratebay.org OR site:mininova.org OR site:torrentspy.com OR site:isohunt.com';
$headerSettings['fmovie'] = ' site:stage6.divx.com OR site:veoh.com OR site:flixdump.com OR site:filmzzz.com OR site:freemoviescinema.com OR site:peekvid.com OR site:myeasytv.com OR site:tv-links.co.uk OR site:guba.com OR site:chooseandwatch.com OR site:videohybrid.com OR site:dailymotion.com OR site:jonhs.net OR site:movieflix.com';
$headerSettings['tvmovie'] = ' site:';
$headerSettings['free_uni'] = ' site:mit.ols.usu.edu OR site:cnx.ols.usu.edu OR site:ocw.mit.edu OR site:cnx.rice.edu OR site:sofia.fhda.edu OR site:ocw.jhsph.edu OR site:ocw.usu.edu OR site:www.twocw.net OR site:mit.ocw.universia.net OR site:ocw.osaka-u.ac.jp OR site:ocw.kyoto-u.ac.jp OR site:ocw.dmc.keio.ac.jp OR site:www.ocw.titech.ac.jp OR site:ocw.u-tokyo.ac.jp OR site:webcast.berkeley.edu OR site:en.wikibooks.org OR site:free.ed.gov OR site:firstgov.gov';
$headerSettings['pdf'] = ' filetype:pdf ';
$headerSettings['ringtones'] = ' intitle:"index.of" "parent directory" "size" "last modified" "description" [snd] (mid|midi|imelody|qcp|rtttl|rtx|sckl|ott) -inurl:asp -inurl:htm -inurl:html -inurl:cf -inurl:jsp';
$headerSettings['youtube'] = 'search_type=search_videos&search_sort=video_view_count&search_category=0&search=Search&so=3&start=0&search_query=';
$headerSettings['wiki'] = '';
$headerSettings['youtube'] = 'search_type=search_videos&search_sort=video_view_count&search_category=0&search=Search&so=3&start=0&search_query=';
$headerSettings['askcom'] = '';
$headerSettings['citeseet'] = 'submit=Search+Documents&cs=1&q=';
$headerSettings['googlescholar'] = '';
$headerSettings['somethingelse'] = ' site:answers.google.com';
// convert $_POST['searchType to lower case so we know we'll match regardless of what the user sends
$_POST['searchType'] = strtolower($_POST['searchType']);
if (isset($headerSettings[$_POST['searchType']]))
{
// have a switch statement to keep it a bit easier
// to add extras, place
// case 'whatyouwanttomatch' :
// $_POST['searchType'] = 'Location: http://myurl.com/search?que' . rawurlencode($headerSettings[$_POST['searchType']] . $_POST['searchTerm');
// break;
// don't touch the default// anything that you want to search with google, just add above, don't add here
switch ($_POST['searchType'])
{
case 'youtube' :
$_POST['searchType'] = 'Location: http://youtube.com/results?' . rawurlencode($headerSettings[$_POST['searchType']] . $_POST['searchTerm']);
break;
case 'wiki' :
$_POST['searchType'] = 'Location: http://en.wikipedia.org/w/index.php?title=Special%3ASearch&search=' . rawurlencode($headerSettings[$_POST['searchType']] . $_POST['searchTerm']);
break;
case 'citeseet' :
$_POST['searchType'] = 'Location: http://citeseer.ist.psu.edu/cis?' . rawurlencode($headerSettings[$_POST['searchType']] . $_POST['searchTerm']);
break;
case 'askcom' :
$_POST['searchType'] = 'Location: http://uk.ask.com/web?q=' . rawurlencode($headerSettings[$_POST['searchType']] . $_POST['searchTerm']);
break;
case 'googlescholar' :
$_POST['searchType'] = 'Location: http://scholar.google.com/scholar?q=' . rawurlencode($headerSettings[$_POST['searchType']] . $_POST['searchTerm']);
break;
// No need to touch the below part at all
default :
$_POST['searchType'] = 'Location: http://www.google.com/search?hl=en&q=' . rawurlencode($headerSettings[$_POST['searchType']] . $_POST['searchTerm']);
}
header ($_POST['searchType']);
exit();
}
?>
|
|
|
October 24th, 2007, 12:14 PM
|
#25
|
|
WebForumz Member
Join Date: Oct 2007
Location: room
Age: 19
Posts: 77
Thanks: 0
Thanked 1 Time in 1 Post
Rep Altering Power: 0
|
Re: Radio Button Response! :(
Heyy, thankyooh for that =D
Here it is :
blizma.co.uk.
It does not search properly, it sort of gives the exact same search results every time.
|
|
|
October 24th, 2007, 12:22 PM
|
#26
|
|
WebForumz Member
Join Date: Oct 2007
Location: room
Age: 19
Posts: 77
Thanks: 0
Thanked 1 Time in 1 Post
Rep Altering Power: 0
|
Re: Radio Button Response! :(
I think it only searched the google dork, but does not put the searchterm infront :S
|
|
|
October 25th, 2007, 04:25 AM
|
#27
|
|
Highly Reputable Member
SuperMember
Join Date: Sep 2007
Location: Australia
Age: 25
Posts: 956
Thanks: 0
Thanked 0 Times in 0 Posts
|
Re: Radio Button Response! :(
You need to make sure that the input names if your form match the index names in the $headerSettings array.
In your form for example you have name="wikipedia" but in the $headerSettings array you have $headerSettings['wiki']
Make sure they match or else you'll always end up of google
Cheers,
|
|
|
October 25th, 2007, 08:03 AM
|
#28
|
|
WebForumz Member
Join Date: Oct 2007
Location: room
Age: 19
Posts: 77
Thanks: 0
Thanked 1 Time in 1 Post
Rep Altering Power: 0
|
Re: Radio Button Response! :(
Hey =D
Oh everything is correct. Google opens with the searchType, but not with the searchTerm.
So it would say = inurl:blaaa
but not = searchTerm inurl:blaaa
Its all uploaded, you can check on the website.
I have tried playing around with trial and error, but can't get it to work =[  
|
|
|
October 25th, 2007, 08:16 AM
|
#29
|
|
Highly Reputable Member
SuperMember
Join Date: Sep 2007
Location: Australia
Age: 25
Posts: 956
Thanks: 0
Thanked 0 Times in 0 Posts
|
Re: Radio Button Response! :(
to get the order back the way you want it switch
rawurlencode($headerSettings[$_POST['searchType']] . $_POST['searchTerm']);
to
rawurlencode($_POST['searchTerm'] . ' ' . $headerSettings[$_POST['searchType']]);
for all of the google searches.
For anything that doesn't have a big string like the google ones, just use
rawurlencode( $_POST['searchTerm']);
|
|
|
October 25th, 2007, 09:09 AM
|
#30
|
|
WebForumz Member
Join Date: Oct 2007
Location: room
Age: 19
Posts: 77
Thanks: 0
Thanked 1 Time in 1 Post
Rep Altering Power: 0
|
Re: Radio Button Response! :(
soo.....
Code:
default :
rawurlencode($_POST['searchTerm'] . 'Location: http://www.google.com/search?hl=en&q=' . $headerSettings[$_POST['searchType']]);
}
header ($_POST['searchType']);
exit();
}
?>
.... =S i have no clue :'(
|
|
|
October 25th, 2007, 09:15 AM
|
#31
|
|
Highly Reputable Member
SuperMember
Join Date: Sep 2007
Location: Australia
Age: 25
Posts: 956
Thanks: 0
Thanked 0 Times in 0 Posts
|
Re: Radio Button Response! :(
Ummm not quite, sorry.. I should have explained better
Here is what it should look like
Code:
<?php
$headerSettings = array();
// for the sake of simplicity, keep all of the index values in lower case
// eg. $header['myname'] as opposed to $header['myName']
$headerSettings['mp3s'] = ' intitle:"index.of" "parent directory" "size" "last modified" "description" [snd] (mp4|mp3|avi|flac|aac|ape|ogg) -inurl:(jsp|php|html|aspx|htm|cf|shtml|lyrics-realm|mp3-collection) -site:.info';
$headerSettings['albums'] = ' site:zshare.net OR site:rapidshare.net OR site:rapidshare.com OR site:megaupload.com OR site:updownloadserver.de OR site:sharebigfile.com OR site:upload.sc OR site:bigfileupload.com OR site:upload2.net';
$headerSettings['torrents'] = ' site:thepiratebay.org OR site:mininova.org OR site:torrentspy.com OR site:isohunt.com';
$headerSettings['fmovie'] = ' site:stage6.divx.com OR site:veoh.com OR site:flixdump.com OR site:filmzzz.com OR site:freemoviescinema.com OR site:peekvid.com OR site:myeasytv.com OR site:tv-links.co.uk OR site:guba.com OR site:chooseandwatch.com OR site:videohybrid.com OR site:dailymotion.com OR site:jonhs.net OR site:movieflix.com';
$headerSettings['tvmovie'] = ' site:';
$headerSettings['free_uni'] = ' site:mit.ols.usu.edu OR site:cnx.ols.usu.edu OR site:ocw.mit.edu OR site:cnx.rice.edu OR site:sofia.fhda.edu OR site:ocw.jhsph.edu OR site:ocw.usu.edu OR site:www.twocw.net OR site:mit.ocw.universia.net OR site:ocw.osaka-u.ac.jp OR site:ocw.kyoto-u.ac.jp OR site:ocw.dmc.keio.ac.jp OR site:www.ocw.titech.ac.jp OR site:ocw.u-tokyo.ac.jp OR site:webcast.berkeley.edu OR site:en.wikibooks.org OR site:free.ed.gov OR site:firstgov.gov';
$headerSettings['pdf'] = ' filetype:pdf ';
$headerSettings['ringtones'] = ' intitle:"index.of" "parent directory" "size" "last modified" "description" [snd] (mid|midi|imelody|qcp|rtttl|rtx|sckl|ott) -inurl:asp -inurl:htm -inurl:html -inurl:cf -inurl:jsp';
$headerSettings['youtube'] = 'search_type=search_videos&search_sort=video_view_count&search_category=0&search=Search&so=3&start=0&search_query=';
$headerSettings['wiki'] = '';
$headerSettings['youtube'] = 'search_type=search_videos&search_sort=video_view_count&search_category=0&search=Search&so=3&start=0&search_query=';
$headerSettings['askcom'] = '';
$headerSettings['citeseet'] = 'submit=Search+Documents&cs=1&q=';
$headerSettings['googlescholar'] = '';
$headerSettings['somethingelse'] = ' site:answers.google.com';
// convert $_POST['searchType to lower case so we know we'll match regardless of what the user sends
$_POST['searchType'] = strtolower($_POST['searchType']);
// have a switch statement to keep it a bit easier
// to add extras, place
// case 'whatyouwanttomatch' :
// $_POST['searchType'] = 'Location: http://myurl.com/search?que' . rawurlencode($headerSettings[$_POST['searchType']] . $_POST['searchTerm');
// break;
// don't touch the default// anything that you want to search with google, just add above, don't add here
switch ($_POST['searchType'])
{
case 'youtube' :
$_POST['searchType'] = 'Location: http://youtube.com/results?' . rawurlencode( $_POST['searchTerm']);
break;
case 'wiki' :
$_POST['searchType'] = 'Location: http://en.wikipedia.org/w/index.php?title=Special%3ASearch&search=' . rawurlencode($_POST['searchTerm']);
break;
case 'citeseet' :
$_POST['searchType'] = 'Location: http://citeseer.ist.psu.edu/cis?' . rawurlencode($_POST['searchTerm']);
break;
case 'askcom' :
$_POST['searchType'] = 'Location: http://uk.ask.com/web?q=' . rawurlencode($_POST['searchTerm']);
break;
case 'googlescholar' :
$_POST['searchType'] = 'Location: http://scholar.google.com/scholar?q=' . rawurlencode($_POST['searchTerm']);
break;
// No need to touch the below part at all
default :
$_POST['searchType'] = 'Location: http://www.google.com/search?hl=en&q=' . rawurlencode($_POST['searchTerm'] . ' ' . $headerSettings[$_POST['searchType']]);
}
header ($_POST['searchType']);
exit();
?>
|
|
|
October 25th, 2007, 11:44 AM
|
#32
|
|
WebForumz Member
Join Date: Oct 2007
Location: room
Age: 19
Posts: 77
Thanks: 0
Thanked 1 Time in 1 Post
Rep Altering Power: 0
|
Re: Radio Button Response! :(
OK.
I spent the last hours filling all of that in. all the radio buttons, and cases etc.
BUT *swears, punches stuff* it doesnt work  i checked everything. it just comes with test. php blank page. Im guesing there is 1 tiny mistake someone like a dash to much, or missing a dash, for the entire page not to work =[.
Im going to find and download a php debugger see if that gets me further.
|
|
|
October 25th, 2007, 02:26 PM
|
#33
|
|
WebForumz Member
Join Date: Oct 2007
Location: room
Age: 19
Posts: 77
Thanks: 0
Thanked 1 Time in 1 Post
Rep Altering Power: 0
|
Re: Radio Button Response! :(
Hmm...
Everything works now!! YAYYYAYAYAYAYYAYYAYAYYAYAYAYAYAYAYAYYAYAYAYAYAYAY
=D man was that a long project =D for me anyway... probably a 1minute job for most people...
There is one final question/error..
when goin to
on iexplorer there are black boxes around the radio buttons =[, on firefox it works fine... is this ment to be?
Also.. most of y scripts are on this forum now.... and can be found by google because the search term blizma is very uncommon, bringing all my posts up on the search.
any way to hide these posts from google?
|
|
|
October 25th, 2007, 06:15 PM
|
#34
|
|
Highly Reputable Member
SuperMember
Join Date: Sep 2007
Location: Australia
Age: 25
Posts: 956
Thanks: 0
Thanked 0 Times in 0 Posts
|
Re: Radio Button Response! :(
There is an option to hide your thread from google if you are a Webforumz Supermember.
Glad it's working 
|
|
|
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|