GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   Batch URL Encoder? (https://gfy.com/showthread.php?t=776812)

beanamid 10-15-2007 07:48 PM

Batch URL Encoder?
 
I need to encode a Ton of URLS for my trade script what's a good batch encoder???

Thanks in advance

bDok 10-15-2007 08:01 PM

write a quick perl script. probs would take a couple lines.

Bro Media - BANNED FOR LIFE 10-15-2007 08:19 PM

make a form, and put a textarea into it, and name it "batchurl" then make encode.php and put this in it

PHP Code:

<?php
if($_POST['batchurl'] == true)
{
   
$newline explode("\n"$_POST['batchurl']);
   foreach(
$newline as $url)
   {
      echo 
urlencode($url) . "<br />\n";
   }
}
?>

make sure to make the form a POST not a GET and then just use the form to execute encode.php

beanamid 10-15-2007 08:40 PM

Quote:

Originally Posted by Jaysin (Post 13240595)
make a form, and put a textarea into it, and name it "batchurl" then make encode.php and put this in it

PHP Code:

<?php
if($_POST['batchurl'] == true)
{
   
$newline explode("\n"$_POST['batchurl']);
   foreach(
$newline as $url)
   {
      echo 
urlencode($url) . "<br />\n";
   }
}
?>

make sure to make the form a POST not a GET and then just use the form to execute encode.php

Thanks a million I owe you one!

Bro Media - BANNED FOR LIFE 10-15-2007 08:58 PM

Quote:

Originally Posted by beanamid (Post 13240668)
Thanks a million I owe you one!

no problem!

beanamid 10-15-2007 09:01 PM

I think I missed somthing..
I make the form, and it looks like this:
<body>
<form action="/encode.php" method="post" enctype="application/x-www-form-urlencoded" name="batchurl"><textarea name="urls to encode" cols="50" rows="20" wrap="off"></textarea><input name="submit" type="submit" /></form>
</body>

I think I am missing somthing.....

beanamid 10-15-2007 09:02 PM

never mind I had the name wrong thanks

Bro Media - BANNED FOR LIFE 10-15-2007 09:17 PM

Quote:

Originally Posted by beanamid (Post 13240743)
never mind I had the name wrong thanks

:thumbsup

beanamid 10-15-2007 09:37 PM

last time I will bug you
could I add the lines:
/out.php?p=85&url=
to the php side
and even better would be to add the lines
<a href="/out.php?p=85&url=URLHERE" target="_blank"></a>

beanamid 10-15-2007 09:39 PM

jaysin thanks for the help and I did signup for profitx under your code (not that I am making much yet)

Bro Media - BANNED FOR LIFE 10-15-2007 09:47 PM

Quote:

Originally Posted by beanamid (Post 13240861)
last time I will bug you
could I add the lines:
/out.php?p=85&url=
to the php side
and even better would be to add the lines
<a href="/out.php?p=85&url=URLHERE" target="_blank"></a>

you want the script to ouput that for each link?

Quote:

Originally Posted by beanamid (Post 13240869)
jaysin thanks for the help and I did signup for profitx under your code (not that I am making much yet)

no worries, its not my refcode, its actually $tandman's who bought my sig, but he'll appreciate it, thanks!

beanamid 10-15-2007 10:51 PM

It would be great if I got this as the end result: (either in the source code or text)
<a href="/out.php?p=85&url=URLHERE" target="_blank"></a>


Thanks again

GrouchyAdmin 10-15-2007 11:01 PM

Change your echo statement.

Code:

echo '<a href="/out.php?p=85&url=' . urlencode($url) . '" target="_blank"></a><br />' . "\n";

beanamid 10-16-2007 07:18 AM

Quote:

Originally Posted by GrouchyAdmin (Post 13241085)
Change your echo statement.

Code:

echo '<a href="/out.php?p=85&url=' . urlencode($url) . '" target="_blank"></a><br />' . "\n";

Thanks for the help.....

Bro Media - BANNED FOR LIFE 10-16-2007 08:11 AM

Quote:

Originally Posted by GrouchyAdmin (Post 13241085)
Change your echo statement.

Code:

echo '<a href="/out.php?p=85&url=' . urlencode($url) . '" target="_blank"></a><br />' . "\n";

there ya go, sorry i didn't reply, i went to bed


All times are GMT -7. The time now is 08:01 PM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc