![]() |
![]() |
![]() |
||||
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
![]() ![]() |
|
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
Thread Tools |
![]() |
#1 |
Confirmed User
Join Date: Sep 2003
Location: Los Begas
Posts: 9,162
|
![]() I have a text file of the form:
word1 word2 word3 word4 word5 etc and I want something that will randomly change the order, for example: word3 word1 word5 word2 word4 Any suggestions? |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#2 |
Push Porn Like Weight.
Industry Role:
Join Date: Mar 2002
Location: Inside .NET
Posts: 10,652
|
what language do you want to use?
in VB i would just have a randomize statement run from the lbound to the ubound of the array and write them to a different file.
__________________
Cry havoc and let slip the dogs of war. |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#3 |
Confirmed User
Join Date: Nov 2003
Location: ThatOneProgram.com
Posts: 9,898
|
<?php
randomize OzMan's text! ?php> j/k, I have no idea, but if that works, cheers man!
__________________
Want to promote SUCCUBUS? Click HERE!!!! | Want to buy SUCCUBUS? Click HERE!!!! Yeah, yeah, you know, That One Program! | Want to trade links with StompBunny.com? Loryn (3:16 PM): I love it, just as long as we keep the bedroom door closed from all ears then we can have throw down hard core sex that makes us money haha fuck it we can have sex on money never did that before |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#4 |
Confirmed User
Join Date: Sep 2003
Location: Los Begas
Posts: 9,162
|
![]() There are a bunch that will sort a file .. alpha numeric ascending descending etc but I wanna do the opposite I guess ![]() |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#5 | |
Confirmed User
Join Date: Apr 2004
Posts: 2,225
|
Quote:
|
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#6 | |
Confirmed User
Join Date: Sep 2003
Location: Los Begas
Posts: 9,162
|
Quote:
![]() anyone else? |
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#8 |
Confirmed User
Join Date: Jul 2004
Posts: 814
|
simple code, and im not a programmer. assign em each a variable, randomize the lot, order from least to greatest.. or somethin
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#9 |
Confirmed User
Industry Role:
Join Date: Jul 2003
Posts: 712
|
PHP Code:
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#10 |
Confirmed User
Join Date: Dec 2004
Location: Vancouver
Posts: 4,325
|
You can use Excel and put your text in column A and then use the rand function in column B then sort.
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#11 |
Too lazy to set a custom title
Industry Role:
Join Date: Jul 2001
Posts: 59,204
|
elistpro ;)
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#12 | |
Confirmed User
Join Date: Jul 2004
Posts: 814
|
Quote:
|
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#13 |
Confirmed User
Join Date: Feb 2005
Posts: 110
|
#!/usr/bin/perl
# Read File while (<>) { push(foo, $_); } # Shuffle lines srand; for (0..$#foo) { $r = rand($#foo+1); ($foo[$r], $foo[$_]) = ($foo[$_], $foo[$r]); } # Print it out for (0..$#foo) { print $foo[$_]; } |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#14 |
Too lazy to set a custom title
Industry Role:
Join Date: Aug 2002
Posts: 55,372
|
$filename = "ban.txt";
$sites = file($filename); srand ((double) microtime() * 1000000); $a = rand(0, sizeof($sites) - 1); echo $sites[$a];
__________________
Since 1999: 69 Adult Industry awards for Best Hosting Company and professional excellence. ![]() WP Stuff |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#16 |
Confirmed User
Join Date: Sep 2003
Location: Los Begas
Posts: 9,162
|
Interesting ideas here Thanks for the info
![]() |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#17 |
So Fucking Outlawed
Industry Role:
Join Date: Nov 2001
Posts: 5,114
|
elistpro
or textpad I think does it .. and it's free |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#18 | |
Confirmed User
Join Date: Mar 2003
Location: Western NY
Posts: 5,114
|
Quote:
![]() |
|
![]() |
![]() ![]() ![]() ![]() ![]() |