Find Jobs
Hire Freelancers

I would like to hire a Web Developer for a Randomized Result Generator (Non-math)

$10-30 USD

Completed
Posted almost 6 years ago

$10-30 USD

Paid on delivery
I manage a wiki-style site that allows for the use of embedded HTML content (through this method, which you may want to reference for the coding: [login to view URL]:html-blocks). As part of my website development, I would like to be able to create and embed random result generators that can output 1 of X fixed text results (typically 100) when a user clicks on a button. Average output will be 1-2 sentences (no math, just text), and I want users to be able to continue to get a random result each time they click on the button. The code should be self-contained on the page and not require reloading to get further results. This generator will need to be on pages with other content, and one page will need to have about two dozen generators. Mobile reactivity is preferred, but not required. To be clear, I am NOT asking you to fill out the results for every generator I need - it's simple copy-paste at that point, and I plan to do that stuff myself. What I need is the completed code that I can put between the HTML tags (as described in the link above), ready for me to copy/paste and insert results to create as many generators as I need. 3 obvious sample results (Result 1, Result 2, Result 3, basically) is all you need to include - as long as it's obvious where to include more results and the generator can accept them, it should be good. For styling, I would prefer to have the button on the left and the output text on the right, but button above and text below is also acceptable. I'd also like it to have a simple, thin gray or blue border to distinguish the generator as a separate piece of content. If you know how to create this code, it *should* be fairly simple and straightforward (said the buyer who doesn't know coding, hah), so I'm offering this as a Micro Project.
Project ID: 16733450

About the project

2 proposals
Remote project
Active 6 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
Awarded to:
User Avatar
Not tested, but this should work, assuming you can use pure Javascript in your HTML blocks <div id="randomResult"></div> <script> var stringArray = ['Text One', 'Text Two', 'Text Three']; var rand = [login to view URL]([login to view URL]() * [login to view URL]); function getResultString(){ [login to view URL]('randomResult').innerHTML = stringArray[rand]; } getResultString(); </script>
$25 USD in 1 day
4.9 (6 reviews)
3.7
3.7

About the client

Flag of UNITED STATES
Marysville, United States
5.0
3
Payment method verified
Member since Apr 18, 2018

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.