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 6847139
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T00:42:32+00:00 2026-05-27T00:42:32+00:00

I’m working on a small app that makes use of the jQuery plugin Fullcalendar.

  • 0

I’m working on a small app that makes use of the jQuery plugin Fullcalendar. This plugin is very good but now I need to make s light change to it.

Once an event has been stored it is presented on the calendar and clicking on the event by default displays an alert with the event title in it. What I want to happen is for the click event to call an an action on my calendar controller.

The javascript that I am using of the fullcalendar.js and then my own javascript library:

function padDigits(n, totalDigits) {

    n = n.toString();

    var pd = '';

    if (totalDigits > n.length) {

        for (i = 0; i < (totalDigits - n.length); i++) {

            pd += '0';

        }

    }

    return pd + n.toString();

}



function createEvent(date, allDay, jsEvent, View) {

    var eventDate = padDigits(date.getMonth() + 1, 2) + '-' +

                    padDigits(date.getDate(), 2) + '-' +

                    padDigits(date.getFullYear(), 4);

    window.location.href = "/Calendar/Create/" + eventDate;

}



$(document).ready(function () {

    $('#calendar').fullCalendar({

        editable: true,

        events: $('#calendar').data('url'), /*"/Calendar/GetEvents",*/

        eventClick: "/Calendar/ReviewApproveBooking", 

        dayClick: function (date, allDay, jsEvent, view) {

            createEvent(date, allDay, jsEvent, view);

        }

    });

});

The eventClick is where I want to make the call.

The action looks like:

[HttpGet]
        [Authorize(Roles="Admin")]
        public ActionResult ReviewApproveBooking()
        {
            var booking = from b in DBContext.Events
                          where b.EventID == 1
                          select b;
            var em = booking.Single();
            Guid memberKey = em.MemberID;
            MembershipUser mu_booker = Membership.GetUser(memberKey);

            ProfileModel pm = ProfileModel.GetProfile(mu_booker.UserName);

            em.BookerName = pm.FullName;

            return View(em);
        }

        [HttpPost]
        [Authorize(Roles="Admin")]
        public ActionResult ReviewApproveBooking(int id, EventModel em)
        {
            // get the actual user ID
            // Need to complete - I know this is blank
            return View();
        }

I’ve been working on this for a day now and I can’t see what I need to do to get this work. Any help is greatly appreciated.

Many thanks
nathj07

  • 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-05-27T00:42:32+00:00Added an answer on May 27, 2026 at 12:42 am

    In short if I am correct, you simply want to make an ajax call when an event is clicked, looking the docs this is fairly simple…

    Firstly you need to call a [Post] method with your ajax call, I am showing you the jquery code below:

    The docs say this..
    $('#calendar').fullCalendar({
        eventClick: function(calEvent, jsEvent, view) {
    
            alert('Event: ' + calEvent.title);
            alert('Coordinates: ' + jsEvent.pageX + ',' + jsEvent.pageY);
            alert('View: ' + view.name);
    
            // change the border color just for fun
            $(this).css('border-color', 'red');
    
        }
    });
    
    $('#calendar').fullCalendar({
        eventClick: function(calEvent, jsEvent, view) {
            $.ajax({
                url: _url,
                type: "POST",
                cache: false,
                data: { id= "",  }, *//sort out your params here*
                error: function(xhr, status, error) {
    //handle errors
                },
                success: function(data) {
    //handle sucess here
    
                } // end on sucess
            }); // end ajax call
    
        }
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I have a jquery bug and I've been looking for hours now, I can't
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
this is what i have right now Drawing an RSS feed into the php,
I have a French site that I want to parse, but am running into
I'm working with an upstream system that sometimes sends me text destined for HTML/XML
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I want to count how many characters a certain string has in PHP, but
For some reason, after submitting a string like this Jack’s Spindle from a text

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.