Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9115843
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T04:31:46+00:00 2026-06-17T04:31:46+00:00

I am using the photo tagging script found here http://www.bryantan.info/jquery/5 Very simple code. It

  • 0

I am using the photo tagging script found here

http://www.bryantan.info/jquery/5 Very simple code.

It works great, but is always in tag enabled mode. How can I implement a button “Tag photo”, which when clicked will enable tagging, and otherwise, the tagging is disabled. Also, When done tagging, this button can be clicked to turn off tagging.

Like facebook tagging.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T04:31:47+00:00Added an answer on June 17, 2026 at 4:31 am

    You need a var that will toggle a Boolean value initially set to false.
    Return your image clicks if that value is false 🙂
    here is how to do it:

    jsBin demo (with basic button functionality)

    var tagEditing = false; // create this line
    

    than add a button somewhere like:

    <button id="startTag">Start tagging</button>
    

    than add into this an if statement:

    $('#tagit #btnsave').live('click',function(){
    
      if( !tagEditing ){
           return;
      }
    
      name = $('#tagname').val();
      counter++;
      $('#taglist ol').append('<li rel="'+counter+'"><a>'+name+'</a> (<a class="remove">Remove</a>)</li>');
      $('#imgtag').append('<div class="tagview" id="view_'+counter+'"></div>');
      $('#view_' + counter).css({top:mouseY,left:mouseX});
      $('#tagit').fadeOut();
      // add backend code here, use mouseX and mouseY for the axis and counter.
      // ............
    
    });
    

    Now you just need to toggle your tagEditing var, button text and image cursor style:

    $('#startTag').click(function(){
       tagEditing = !tagEditing;
    
       $('#imgtag').css({cursor: tagEditing? 'crosshair' : 'default' });
       $(this).text(tagEditing? 'End tagging':'Start tagging');
    });
    

    and also on upload :

    $('#yourUploadButton').click(function(){
    
        tagEditing = false;
    
    });
    

    Additionally if var tagEditing == false you’d like to change the image cursor style from crosshair to default (look in the demo to see how)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using the photo slider code from here: http://tympanus.net/codrops/2010/10/07/slider-gallery/ and trying to modify it
I'm creating a site using a photo slider like http://www.queness.com/resources/html/scroll/horizontal.html and here is my
I am using pretty photo to display videos - It pretty much works as
I am using below code to generate photo gallery from a folder. How can
Using this standard code: NSMutableDictionary *params = [NSMutableDictionary dictionary]; [params setObject:image forKey:@photo]; [params setObject:text
I am writing a simple photo viewer in C++ using gtkmm and I can
I am having a problem trying to 'like' a photo using JQuery. I've tried
I am making a photo gallery using jQuery and I want to have a
Facebook recently added photo-tagging capabilities to its Graph API: http://developers.facebook.com/blog/post/509/ I am using FbConnect
I'm creating a photo tagging project using mysql and php, that not only just

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.