nowrap with Image and Checkbox

Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.

  1. #1

    Default nowrap with Image and Checkbox

    Hi eveyone -

    I am outputing images with checkboxes to a display page and I am having
    problems getting the checkbox to "stick" with the image. Whats currently
    happening is the checkbox may or maynot appear to the right of the outputed
    image. I want it to allways appear to the right. Sometimes what happens is the
    browser window expands and the cells expand (by design) however as this occures
    the checkbox for an image may drop down to the next line. I hope I am making
    sence here so please ask me for further clarification if you dont understand!
    (see code)

    Thank you in advance!!!!

    <span class="bodymedium">Click to Enlarge Images </span>
    <form name="form" method="post" action="">
    <br>
    <cfoutput query="GetImages">
    <a
    href="imageinfo.cfm?Image=#GetImages.Image_Path#&I mageID=#GetImages.ImageID#&Cal
    ledPage=thispage.cfm"><img src="Images/#GetImages.Image_Thumb#" border="0"
    alt="Click to Enlarge"></a>
    <input name="checkbox" type="checkbox" value="#GetImages.ImageID#">
    </cfoutput> <br>
    <br>
    <input type="submit" name="Submit" value="Add to Favorites">
    </form>

    jolejni Guest

  2. Similar Questions and Discussions

    1. checkbox
      I know there is a way to update records with a checkbox. Is there a way to update this records (with different value)by unchecking the checkbox?
    2. 'nowrap' available in flash forms?
      When using formgroup=hbox,horizontal,hdividedbox I'm still having issues with the page not forcing horizontal-ness. Instead of a dynamic scroll...
    3. Howto bind CheckBox to the datagrid/ Then update the database field when the checkbox is clicked.
      I am trying to update the database field when the checkbox is clicked. I am trying to modified the following solution but.. got stuck on the...
    4. The nowrap Property of TD Tags
      I want to create TD tags with the nowrap property. I have a user control which sets the Wrap property of a TableCell to False when dynamically...
    5. DIV, CheckBox
      Hello, I am populating a DIV with Checkboxes based on rows I get from a Table while dr.read() ..... mydiv.controls.add(etc...) .... other set...
  3. #2

    Default Re: nowrap with Image and Checkbox

    The problem is that the <input name="checkbox"... is on a different line from
    the img tag. This creates a "white space" and causes a break to occur. Code
    it like this:

    ...alt="Click to Enlarge"</a><input name="checkbox"...

    jdeline Guest

  4. #3

    Default Re: nowrap with Image and Checkbox

    I tried it as you suggested however it is still wrapping the checkbox to the
    next line if the browser is expanded or shinked...any suggestions?

    <img src="Images/#GetImages.Image_Thumb#" border="0" alt="Click to
    Enlarge"</a><input name="checkbox" type="checkbox" value="#GetImages.ImageID#">

    Thank you again!!

    jolejni Guest

  5. #4

    Default Re: nowrap with Image and Checkbox

    You can try putting the image and checkbox in a table cell with the NOWRAP attribute, or in adjoing table cells on the same row.

    -Paul
    dempster Guest

  6. #5

    Default Re: nowrap with Image and Checkbox

    I tried several differnt things (div, td and tr) with no avail. I also set the nowrap on the table cell and it worked, however all the images expaned accross the screen.

    hmmm, not sure on this!
    jolejni Guest

  7. #6

    Default Re: nowrap with Image and Checkbox

    Please post your current code snippet.
    jdeline Guest

  8. #7

    Default Re: nowrap with Image and Checkbox

    Here you go! Thanks!
    <form name="imageform" method="post" action="">
    <div align="left">
    <cfif isdefined("session.arrMyFav")>
    <cfloop index="idx" from="1"
    to="#ArrayLen(session.arrMyFav)#">
    <cfoutput> <img
    src="../galleries/Images/#session.arrMyFav[idx][2]#">
    <select name="Sel#idx#"
    onChange="MM_goToURL('parent','Builder.cfm?Frame=# URL.Frame#&amp;Image=#session.
    arrMyFav[idx][1]#&amp;Quad= ' + document.imageform.Sel#idx#.value);return
    document.MM_returnValue">
    <option value="...">Click Here</option>
    <cfloop index="idx" from="1"
    to="#Get_Frame.Frame_Quad#">
    <option value="#idx#">Image
    #idx#</option>
    </cfloop>
    </select>
    </cfoutput>
    </cfloop>
    </cfif>
    </div>
    </form>

    jolejni Guest

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139