Support » Plugins » inline-uploading.php – important image question

  • Under the ‘// Construct the attachment array’ section, how do I get the code to include ‘rel=”lightbox”‘ in the HTML it generates for the uploaded image to be displayed?

    I want the code to look like:

    < a rel=”lightbox” class=”imagelink” href=”IMG.jpg”>

    Any help REALLY appreciated hugely.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Bump. Anyone have any ideas with this?

    Okay. I’m not sure what you mean by // Construct the attachment array’ section. A little more information would be nice.

    But if you’re talking about using the img button inside Write /Post, you need to state the IMAGE URL path (where you store your images on your server), and then give a description of the image itself.

    You can modify whatever else you need to in the HTML inside the post you’re working on.

    Also an IMAGE URL doesn’t have a href in the tag. It does have img src. You can wrap the image within a link using HTML by doing this:

    [a href=”url” title=”lightbox”][img src=”imageurl.jpg” alt=”descript of piccy” class=”imagelink” /][/a]

    hope that helps

    Edit: See also here for other replies to same question.

    I’ll try to be a little more specific by being a little less complicated..

    We upload an image using the upload form on the Write/Post page. We then send it to the editor as a thumbnail that is linked to the full-size image. WordPress generates the HTML for the image when it sends the thumbnail to the editor.

    What I want to do is add a tag inside the HTML it generates. The HTML would include the IMG tag, the TITLE tag and the A HREF tag. I want to include one more tag in this circumstance.

    I really hope this is clearer to understand.

    The HTML would include the IMG tag, the TITLE tag and the A HREF tag.

    Okay. You must be running a different version of WordPress to me, because as I stated above the image upload via Write/Post does not insert [a href] link within an image tag.

    WordPress generates the HTML for the image when it sends the thumbnail to the editor.

    I don’t know anything about an editor, but the software that drives WordPress produces semantically correct HTML for image tags because images are images – not links. There is a difference.

    You can wrap your image within a hyperlink, as semantically correct HTML thus making the image ‘clickable”.

    I understand you wish to cut down on valuable time, but seriously when you consider the time spent writing a post versus a microsend spent inserting additional HTML inside an image tag is hardly something to worry about.

    I’m sorry. I think I may be wasting more of your time pondering this problem than I’d spend manually inserting a tag. I’ll let this topic die. Thank you for your thoughtful advice on this and the other topics.

    No please, I really need this too. When you have a page that use a lot of images and users that don’t know html at all it’s very nice if it’s automatic.

    there’s a bit of confusion here… the original question asked how to insert a bit of code into an img tag, he meant to ask how to add it to the ahref tag of an img.

    Lightbox is a little plugin that let’s you display thumbnails on your page, and when someone clicks on one, it pops it up onscreen in a cool way. To use the plugin, you upload your photo, then pick “using thumbnail” and “linked to image”. the “linked to image” part adds the ahref tag around the img tag. we need to know how to add in some code that gets passed across when it makes the ahref tag that surrounds the img tag

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘inline-uploading.php – important image question’ is closed to new replies.