Results 1 to 10 of 10

Thread: HTML Generator Window Thingy

  1. #1
    Join Date
    Sep 2006
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question HTML Generator Window Thingy

    I don't really know what it's called. You know how when you go to a generator site, and it generates (whatever) and gives you the HTML to cut/copy/paste? I am looking for a script in HTML that will allow me to place that on my site with my own HTML coding inside for people to copy. Can anyone help me? An example of what I'm asking for is here: http://www.glittertextgenerator.net/index.php See the little boxes w/ HTML in them for people to copy?? That's what I want.

    THanks! )

    PS: You may have to retype something and hit "Do It!" before you'll see what I'm talking about). For some reason, it doesn't save to the original page I posted.

  2. #2
    Join Date
    Mar 2006
    Location
    Illinois, USA
    Posts
    12,162
    Thanks
    263
    Thanked 690 Times in 678 Posts

    Default

    That's complex, but not too difficult, once you have the server side code started.

    Using PHP, you could do this, as with ASP, etc.

    You can send the form data to the page, and get that data; then for each letter, output the image tag/src, then print all of that and place it in a box.
    Daniel - Freelance Web Design | <?php?> | <html>| espa˝ol | Deutsch | italiano | portuguŕs | catalÓ | un peu de franšais | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum

  3. #3
    Join Date
    Sep 2006
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thanks, but..... HUH??? I want to put this code on a "free" site. (Freewebs, to be exact). i don't want letters. The letters thing was just an example. What I'm actually speaking of is the ACTUAL BOX that contains HTML that people copy to paste in their own myspace, or whatever.

  4. #4
    Join Date
    Mar 2006
    Location
    Illinois, USA
    Posts
    12,162
    Thanks
    263
    Thanked 690 Times in 678 Posts

    Default

    The box is just a textarea within a form:
    Code:
    <form .....>
    <textarea .....>any text you want goes here including any html tags</textarea>
    </form>
    Replace the .....s with parameters, like the action of the form and the styling.

    I'm not sure if you want more info because the site you linked to is quite complex. It has a form, yes, but you would also need to generate the result for that. Just having the form doesn't need any server side code, though.
    Also, freewebs doesn't support PHP, etc., so you won't be able to make a generator. You can, though, have a textbox from which you can cut/paste code.


    Note: the reason it doesn't "save the original page" is that it is a PHP script that checks if the form has been sent (and if the info is valid). If so, it generates the preview and the textboxes. If it wasn't sent, then you get no form displayed.
    Daniel - Freelance Web Design | <?php?> | <html>| espa˝ol | Deutsch | italiano | portuguŕs | catalÓ | un peu de franšais | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum

  5. #5
    Join Date
    Sep 2006
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Ok, thank you. Yeah, I don't want a generator -- just the box thingy w/ the HTMl in it for people to highlight and copy. But I can use what you typed out, though, right?? (I hope)? As far as parameters, does that include the size of the HTML box? How would I do that? Do I need quotes and/or spaces, etc.?

  6. #6
    Join Date
    Mar 2006
    Location
    Illinois, USA
    Posts
    12,162
    Thanks
    263
    Thanked 690 Times in 678 Posts

    Default

    <textarea cols="10" rows="40">any code you want</textarea>

    cols is the number of columns; rows is the number of rows of characters. rows are taller than cols are wide; that [10x40] may be roughly square... just a guess.
    Daniel - Freelance Web Design | <?php?> | <html>| espa˝ol | Deutsch | italiano | portuguŕs | catalÓ | un peu de franšais | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum

  7. #7
    Join Date
    Sep 2006
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Ok, thanks so much! I'll try that and let you know how it turns out.

  8. #8
    Join Date
    Sep 2006
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    OK... What was I supposed to put after <form .....> ?

  9. #9
    Join Date
    Mar 2006
    Location
    Illinois, USA
    Posts
    12,162
    Thanks
    263
    Thanked 690 Times in 678 Posts

    Default

    Well, a form is a section of the page with inputs, like textareas, checkboxes, textboxes, and submit buttons. Then the results are sent to the next page.
    But it doesn't seem like you even need to submit this. Just meant to display the textarea.
    So, you should be able to just skip the form all together and just have the textarea.

    There's a chance this page might not validate because the browser would expect a form, in which case you could just put it in a very basic form tag, like:
    <form action="" method="post" onSubmit="return false;">
    <textarea> ....... </textarea>
    </form>

    I'm not sure how many parameters are actually required on the form tag to make it valid, so you might be able to just use <form>, too.

    The rest are just making it do nothing:
    action="" [send the data to the current page]
    method="post" [send via the post method-- or you could use get, but that would put the data as part of the url]
    onSubmit="return false;" [when you submit it... don't-- skip submission]

    Anyway, you probably don't need the form tag. It certainly isn't needed for functionality, but it *might* not validate. Not sure on the rules there.
    Daniel - Freelance Web Design | <?php?> | <html>| espa˝ol | Deutsch | italiano | portuguŕs | catalÓ | un peu de franšais | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum

  10. #10
    Join Date
    Sep 2006
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thanks so much for your help! I thought you might like to see how it turned out, so here's the link:

    http://www.freewebs.com/cherylsmith/...acelayouts.htm

    Now, If I could just figure out an easier way to show a preview of the layouts. ...lol

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •