Write simple generator code ? menu

User Tag List

Results 1 to 7 of 7
  1. #1
    kai95's Avatar Member
    Reputation
    1
    Join Date
    May 2013
    Posts
    23
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Write simple generator code ?

    Hi, I need help with writing simple code which generate numbers 1-9 letters A-Z ? I try it at Excel 2013 with command =ADR.POŚR("B"&LOS.ZAKR(1;25)) & " - " & LICZBA.CAŁK(LOS()*9)+1 where "B" was A-Z but meybe do you have any other ideas? Also 2 first letter have to be always the same.

    Write simple generator code ?
  2. #2
    ev0's Avatar ★ Elder ★ murlocs.com

    CoreCoins Purchaser Authenticator enabled
    Reputation
    1852
    Join Date
    Jul 2012
    Posts
    2,735
    Thanks G/R
    313/379
    Trade Feedback
    16 (100%)
    Mentioned
    7 Post(s)
    Tagged
    7 Thread(s)
    Simple to do in any language really:

    PHP Code:

    function generateRandomString($length 10) {    
    $characters '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ';   
     
    $randomString '';  
      for (
    $i 0$i $length$i++) 

           
    $randomString .= $characters[rand(0strlen($characters) - 1)];  
      }    
    return 
    $randomString

    PHP Code:
    <?
    echo generateRandomString();
    ?>
    If you want to change the length of the string, change it where the function pulls it's values

    PHP Code:
    $length 10 
    and to combat your "first letter always has to be the same", you can spoof it with a AA in the return value or echo
    Need a guild in the US? Visit murlocs.com

  3. #3
    kai95's Avatar Member
    Reputation
    1
    Join Date
    May 2013
    Posts
    23
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks but could you write it when first two letter be NV ?and length be NV3-5-5-5 ?

  4. #4
    ev0's Avatar ★ Elder ★ murlocs.com

    CoreCoins Purchaser Authenticator enabled
    Reputation
    1852
    Join Date
    Jul 2012
    Posts
    2,735
    Thanks G/R
    313/379
    Trade Feedback
    16 (100%)
    Mentioned
    7 Post(s)
    Tagged
    7 Thread(s)
    Originally Posted by kai95 View Post
    Thanks but could you write it when first two letter be NV ?and length be NV3-5-5-5 ?
    Code:
    function generateRandomString($length) {    
        $characters = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ';
        $randomString = '';
        for ($i = 0; $i < $length; $i++) {
            $randomString. = $characters[rand(0, strlen($characters) - 1)];
        }
        return $randomString;
    }
    PHP Code:
    <?
    echo "NV-" . generateRandomString(3) . "-" . generateRandomString(5) . "-" . generateRandomString(5) . "-"generateRandomString(5) . ";
    ?>
    **** these forums and breaking my lines

    i'm at work, not 100% sure if these work perfectly, i'm getting yelled at by my co-workers. Let me know
    Last edited by ev0; 06-30-2014 at 05:31 PM.
    Need a guild in the US? Visit murlocs.com

  5. #5
    kai95's Avatar Member
    Reputation
    1
    Join Date
    May 2013
    Posts
    23
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    wrr idk meybe i do something wrong

  6. #6
    ev0's Avatar ★ Elder ★ murlocs.com

    CoreCoins Purchaser Authenticator enabled
    Reputation
    1852
    Join Date
    Jul 2012
    Posts
    2,735
    Thanks G/R
    313/379
    Trade Feedback
    16 (100%)
    Mentioned
    7 Post(s)
    Tagged
    7 Thread(s)
    Originally Posted by kai95 View Post
    wrr idk meybe i do something wrong

    http://profilerequests.com/random/index.php - there ya go

    EDIT:

    http://profilerequests.com/random/index.php?letters=DD <-- You can set the first 2 letters here

    Code:
    <?
    
    function generateRandomString($length) {
        return substr(str_shuffle("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"), 0, $length);
    }
    
    
    $get = $_GET['letters'];
    
    
    echo $get."-" . generateRandomString(3) . "-" . generateRandomString(5) . "-" . generateRandomString(5) . "-".generateRandomString(5);
    
    
    ?>
    Last edited by ev0; 06-30-2014 at 06:34 PM.
    Need a guild in the US? Visit murlocs.com

  7. #7
    kai95's Avatar Member
    Reputation
    1
    Join Date
    May 2013
    Posts
    23
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Yes, Great Work thank you for help

Similar Threads

  1. [Hack] [No Memory Write] Simple Fly Hack
    By DarkLinux in forum World of Warcraft Bots and Programs
    Replies: 330
    Last Post: 01-15-2015, 07:39 AM
  2. Replies: 1
    Last Post: 05-07-2013, 09:02 AM
  3. Looking for someone who can write simple HB plugin for me
    By HI5 in forum WoW Bots Questions & Requests
    Replies: 5
    Last Post: 09-21-2012, 05:10 PM
  4. Need someone to check a simple SQL code will +rep
    By dude891 in forum World of Warcraft Emulator Servers
    Replies: 10
    Last Post: 03-28-2008, 08:04 PM
All times are GMT -5. The time now is 03:54 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search