Support

Home Forums Event Espresso Premium Need some help with ticketing, recurring and calendar

Need some help with ticketing, recurring and calendar

Posted: April 3, 2013 at 8:53 pm

Viewing 27 reply threads


Richard Dean

April 3, 2013 at 8:53 pm

I am very new to wordpress having mainly used other CMS systems in the past but really liked the look of Event Espresso so decided to give it a go.

I have setup a recurring event that can be booked everyday.

The event is a bus that drives around to schools and they teach children music.

The bus has room for 60.

Now everything is setup but I have a few issues:

1) I would like to add a surcharge of $50 for the bus and each child on the bus is $10, unfortunately this plugin adds $50 onto each ticket sale not just a one of surcharge?

2) When a school makes a booking I want the event to close so no one else can book on the same day, is there anyway to do this without having to sell all 60 seats.

3) I would like to pre-approve all sales first before the transaction is processed through paypal, what option do I need to change in a recurring event so that the event is reviewed first and then approved?

4) For some reason I can’t see the Espresso Calendar widget I am guessing there is a clash in jquery? I have tried to disable all the other plugins but makes no difference.

The site is using these 4 pages for the moment, and the calendar widget doesn’t appear on any of them like it should:

http://themagicbus.com.au/
http://themagicbus.com.au/products-page/
http://themagicbus.com.au/bookings/
http://themagicbus.com.au/contacts/

The widget should be on the left hand side of the footer.

Any help or suggestions would be much appreciated.


Dean

April 4, 2013 at 1:28 am

Hi,

1) I would like to add a surcharge of $50 for the bus and each child on the bus is $10, unfortunately this plugin adds $50 onto each ticket sale not just a one of surcharge?

Yeah the surcharge is on a per ticket basis, we donรถt have the functionality for a one off fee like that as most events run on a per ticket basis. So you could add a surcharge of $1.00 to each ticket so a full bus would get you $60 back.

2) When a school makes a booking I want the event to close so no one else can book on the same day, is there anyway to do this without having to sell all 60 seats.

Unfortunately not no, unless you manually edit the event or have it set up differently (i.e. have the attendee limit set to 1 so that they are buying the bus rather than the individual seats).

3) I would like to pre-approve all sales first before the transaction is processed through paypal, what option do I need to change in a recurring event so that the event is reviewed first and then approved?

In the General Settings, scroll down to the Advanced Settings and turn on “Enable attendee pre-approval feature?” (set to yes)

4) For some reason I canโ€™t see the Espresso Calendar widget I am guessing there is a clash in jquery? I have tried to disable all the other plugins but makes no difference.

Yes there is a jQuery issue. The themes custom js is using the $ version of jQuery without having it in no conflicts mode as WordPress doesnt allow the $ usage out of the box.
http://codex.wordpress.org/Function_Reference/wp_enqueue_script#jQuery_noConflict_Wrappers

Please note that the calendar widget should not appear on the same page that the Calendar is on (due to conflict issues).

I hope that helps let us know if you have any more questions.


Richard Dean

April 4, 2013 at 8:43 pm

Thank you for answers, I have looked at the link provided and have done a bit of research on jquery conflict with wordpress.

Now I am confused should I be editing the Header(header.php) or Theme Functions (functions.php)?

I am looking at the code for both and they seem different to the examples provided.


Richard Dean

April 4, 2013 at 8:44 pm

Theme Functions:

<?php

$functions_path = TEMPLATEPATH . &#039;/functions/&#039;;
$includes_path = TEMPLATEPATH . &#039;/includes/&#039;;

//Loading jQuery and Scripts
require_once $includes_path . &#039;theme-scripts.php&#039;;

//Widget and Sidebar
require_once $includes_path . &#039;sidebar-init.php&#039;;
require_once $includes_path . &#039;register-widgets.php&#039;;

//Theme initialization
require_once $includes_path . &#039;theme-init.php&#039;;

//Additional function
require_once $includes_path . &#039;theme-function.php&#039;;

//Shortcodes
require_once $includes_path . &#039;theme_shortcodes/shortcodes.php&#039;;
include_once(TEMPLATEPATH . &#039;/includes/theme_shortcodes/alert.php&#039;);
include_once(TEMPLATEPATH . &#039;/includes/theme_shortcodes/tabs.php&#039;);
include_once(TEMPLATEPATH . &#039;/includes/theme_shortcodes/toggle.php&#039;);
include_once(TEMPLATEPATH . &#039;/includes/theme_shortcodes/html.php&#039;);

//tinyMCE includes
include_once(TEMPLATEPATH . &#039;/includes/theme_shortcodes/tinymce/tinymce_shortcodes.php&#039;);










// removes detailed login error information for security
add_filter(&#039;login_errors&#039;,create_function(&#039;$a&#039;, &quot;return null;&quot;));

if ( !function_exists( &#039;optionsframework_init&#039; ) ) {


/*-----------------------------------------------------------------------------------*/
/* Options Framework Theme
/*-----------------------------------------------------------------------------------*/

/* Set the file path based on whether the Options Framework Theme is a parent theme or child theme */

if ( STYLESHEETPATH == TEMPLATEPATH ) {
    define(&#039;OPTIONS_FRAMEWORK_URL&#039;, TEMPLATEPATH . &#039;/admin/&#039;);
    define(&#039;OPTIONS_FRAMEWORK_DIRECTORY&#039;, get_bloginfo(&#039;template_directory&#039;) . &#039;/admin/&#039;);
} else {
    define(&#039;OPTIONS_FRAMEWORK_URL&#039;, STYLESHEETPATH . &#039;/admin/&#039;);
    define(&#039;OPTIONS_FRAMEWORK_DIRECTORY&#039;, get_bloginfo(&#039;stylesheet_directory&#039;) . &#039;/admin/&#039;);
}

require_once (OPTIONS_FRAMEWORK_URL . &#039;options-framework.php&#039;);

}

// Removes Trackbacks from the comment cout
add_filter(&#039;get_comments_number&#039;, &#039;comment_count&#039;, 0);
function comment_count( $count ) {
    if ( ! is_admin() ) {
        global $id;
        $comments_by_type = &amp;separate_comments(get_comments(&#039;status=approve&amp;post_id=&#039; . $id));
        return count($comments_by_type[&#039;comment&#039;]);
    } else {
        return $count;
    }
}


// enable shortcodes in sidebar
add_filter(&#039;widget_text&#039;, &#039;do_shortcode&#039;);

// custom excerpt ellipses for 2.9+
function custom_excerpt_more($more) {
    return &#039;Read More &raquo;&#039;;
}
add_filter(&#039;excerpt_more&#039;, &#039;custom_excerpt_more&#039;);
// no more jumping for read more link
function no_more_jumping($post) {
    return &#039;&nbsp;<a>ID).'" class="read-more"&gt;'.'Continue Reading'.'</a>';
}
add_filter('excerpt_more', 'no_more_jumping');


// category id in body and post class
function category_id_class($classes) {
    global $post;
    foreach((get_the_category($post-&gt;ID)) as $category)
        $classes [] = 'cat-' . $category-&gt;cat_ID . '-id';
        return $classes;
}

add_filter('post_class', 'category_id_class');
add_filter('body_class', 'category_id_class');

?>


Richard Dean

April 4, 2013 at 8:45 pm

Header:

<html >

&lt;meta name=&quot;description&quot; content=&quot;" /&gt;
&lt;meta charset=&quot;" /&gt;

<link rel="icon" href="/favicon.ico” type=”image/x-icon” />
<link rel="pingback" href="” />
<link rel="alternate" type="application/rss+xml" title="” href=”” />
<link rel="alternate" type="application/atom+xml" title="” href=”” />

    <a href="http://www.microsoft.com/windows/internet-explorer/default.aspx?ocid=ie6_countdown_bannercode"></a>

<link rel="stylesheet" type="text/css" media="all" href="/css/normalize.css” />
<link rel="stylesheet" type="text/css" media="all" href="” />
<link rel="stylesheet" type="text/css" media="all" href="/css/grid.css” />
<?php
/* We add some JavaScript to pages with the comment form
* to support sites with threaded comments (when in use).
*/
if ( is_singular() && get_option( 'thread_comments' ) )
wp_enqueue_script( 'comment-reply' );

    /* Always have wp_head() just before the closing 
     * tag of your theme, or you will break many plugins, which
     * generally use this hook to add elements to  such
     * as styles, scripts, and meta tags.
     */
    wp_head();
?&gt;

.border {
  behavior:url(/PIE.php)
  }




// initialise plugins
    jQuery(function(){
        // main navigation init
        jQuery('ul.sf-menu').supersubs({ 
            minWidth:    15,   
            maxWidth:    27,  
            extraWidth:  1   
        }).superfish();  
        jQuery('ul.sf-menu').superfish({
            delay:       ,      // one second delay on mouseout 
            animation:   {opacity:'',height:''}, // fade-in and slide-down animation 
            speed:       '',  // faster animation speed 
            autoArrows:  false,   // generation of arrow mark-up (for submenu) 
            dropShadows: false   // drop shadows (for submenu)
        }).children('li').each(function(i){jQuery(this).addClass("color-"+(i+=1));});

        jQuery("ul.list-style-3 li:nth-child(2n)").addClass("color1");
        jQuery("ul.list-style-3 li:nth-child(3n)").addClass("color2");

    });

    // Init for audiojs
    audiojs.events.ready(function() {
        var as = audiojs.createAll();
    });



    jQuery(window).load(function() {
        // nivoslider init
        jQuery('#slider').nivoSlider({
            effect: '',
            slices:,
            boxCols:,
            boxRows:,
            animSpeed:,
            pauseTime:,
            directionNav:,
            directionNavHide:,
            controlNav:,
            captionOpacity:1
        });
        jQuery("#slider-widget").stop().animate({right:"20px"}, {easing:"easeOutBack"});
    });

    /* Body styling options */


/* Header styling options */


    /* Links and buttons color */


    /* Body typography */

<body >

    &lt;a href=&quot;/" title=""&gt;</a>

    &lt;a href=&quot;/" title=""&gt;</a>





      &lt;a href=&quot;/" id="logo"&gt;&lt;img src=&quot;" alt="" title=""&gt;</a>

      &lt;a href=&quot;/" id="logo"&gt;&lt;img src=&quot;/images/logo.png" alt="" title=""&gt;</a>





   'ul', 
        'menu_class'      =&gt; 'sf-menu', 
        'menu_id'         =&gt; 'topnav',
        'depth'           =&gt; 0,
        'theme_location' =&gt; 'header_menu' 
        )); 
      ?&gt;
<!--.primary-->


    <!-- Widgetized Header -->

<!--#widget-header-->     <!--.container-->






            <!-- Widgetized Slider -->


Dean

April 5, 2013 at 12:28 am

That was a lot of code! May be best to use a service like Pastebin in the future, plus our forums tend to strip code out making it hard to read.

OK, neither file had what we are looking for, but there was reference to another file containing more functions theme-function.php which may contain it.


Richard Dean

April 5, 2013 at 5:13 am

Thanks for the pastebin tip, never heard of it before ๐Ÿ™‚
Here are those two files again so you can see them clearly

Here is the functions.php file
http://pastebin.com/zanqHXKp

Here is the header.php file
http://pastebin.com/XHzQNZ5L

Here is the file you suggested:

This is the theme-function.php
http://pastebin.com/KgUMKXyM


Dean

April 5, 2013 at 5:39 am

Hi

Thanks for that.

I had another look at the site as I cant see what I thought was happening in the files.

Looks like I was slightly wrong, so apologies for that.

It is still a jQuery error and still due to the fact it is using $ instead of jQuery, but I was looking in the wrong place.

The file causing the issue is custom.js, found in themes/theme1336/js/custom.js.

Now the name suggests this may contain code you added in the theme options(this is a guess) but it may just be a name the developer gave it.

If you replace the $’s in that file with jQuery it should start working, or at the least show the next error.

As an aside, the theme is loading an old version of jQuery (ver 1.6.4) instead of the default loaded with WordPress (1.7.2 as per your WP version, 1.8.4 is the latest) – it might be loading them from theme-scripts.php

Also, I would advise updating WordPRess, it looks like you are still using an old release candidate version.


Richard Dean

April 5, 2013 at 6:29 am

Ok so I have updated wordpress to the lastest version & I have updated custom.js like you suggested. So the calendar is working on the homepage but still not working on the products page, bookings page (I understand the widget conflicts with the full size calendar) & the contacts page.

So should I now update the theme-scripts.php file? To point to jquery somewhere else?

theme-scripts.php
http://pastebin.com/DKyn1Pbb

Or am I going to have to rewrite the jquery that controls the old theme from the template?


Josh

  • Support Staff

April 5, 2013 at 11:38 am

Hi Richard,

Have you checked to see if the theme has been updated to use a more recent version of jQuery? When a theme hard codes a specific version like 1.6.4, it nevitably will lead to compatibility issues down the road. Right now, WP is shipping with jQuery version 1.8 so we need to write our scripts to be compatible with what WP scripts.

You could try commenting out the lines where it deregisters the WP included jQuery library:

p_deregister_script('jquery');
wp_register_script('jquery', get_bloginfo('template_url').'/js/jquery-1.6.4.min.js', false,'1.6.4');

which will make the theme load the WP included version.


Richard Dean

April 5, 2013 at 6:08 pm

Ok we seem to have made some progress, I have done your latest recommendations, as the widget appears on the products page now but still not on the other pages.

This is where it gets weird if I set the homepage to a static page the widget disappears.

If I create a blank page the widget disappears.

So I have no idea why the widget is ok on these pages:
http://themagicbus.com.au/
http://themagicbus.com.au/products-page/

But on these pages it doesn’t appear:
http://themagicbus.com.au/contacts/
http://themagicbus.com.au/test/
http://themagicbus.com.au/ when the homepage is a static page not a blog with your latest posts.


Sidney Harrell

April 7, 2013 at 6:49 pm

Are all those pages using the same theme page templates?


Richard Dean

April 7, 2013 at 7:05 pm

All pages are using the same theme template and options, would you like me to email the backend details to have a look what is going on?


Dean

April 8, 2013 at 12:11 am

Is it possible to get your login details in order to look into this?

If so, please send them via https://eventespresso.com/send-login-details/

NOTE: login details need to be Admin level.


Richard Dean

April 9, 2013 at 1:44 am

Anyone had a chancd to figure out what is causing the conflict?


Dean

April 9, 2013 at 2:42 am

Hi Richard,

I have had a look at your site and I know what the issue is. Widget Logic plugin. For whatever reason (and I am unsure why) it is conflicting with out widget. Deactivating Widget Logic allows the calendar to show on the pages where it previously didn’t.

You could try playing around with the conditionals or just deactivate.


Richard Dean

April 9, 2013 at 2:58 am

Ok that has done the trick now I have the problem of the widget and the calendar conflicting, is there anyway to deactivate the widget so it doesn’t appear on that page?

Sorry I am use to using Joomla to build sites rather then wordpress, in Joomla you can assign what pages you want a module to appear, wordpress doesn’t seem to give you the same luxury?

http://themagicbus.com.au/bookings/


Dean

April 9, 2013 at 3:05 am

Hi Richard, yes there is. If you go to the Calendar widget and where it says “Calendar Page” add the url for the page with the calendar on. IT will disable the calendar widget if the calendar itself is showing.


Richard Dean

April 9, 2013 at 3:45 am

Still showing up ๐Ÿ™


Dean

April 9, 2013 at 4:42 am

Well, it did work, but not as hoped, it removed the calendar from the footer widget. What I don’t understand and I am still looking into is why the page is showing two calendars.

It is as if there is a hard coded calendar somewhere but no templates seem to be modified or anything like that.

Would you mind if I did some testing by disabling the theme/plugins etc. It will temporarily make the site look weird.


Richard Dean

April 9, 2013 at 4:46 am

Sorry still not showing up after for some reason it is showing 2 calendars ๐Ÿ™ even though I have put the url into the widgets settings


Dean

April 9, 2013 at 4:50 am

Hi,

Yes I know, am I ok to do some testing with the theme and plugins?


Richard Dean

April 9, 2013 at 5:19 am

You can do whatever you like to the site ๐Ÿ™‚ it isn’t really live yet even though it is online


Dean

April 9, 2013 at 5:39 am

Hi,

I spent a little while having a look at this, and the most I have been able to deduce is that the theme is causing the issue.

When swapped to a default theme like TwentyTwelve, only one copy of the calendar is shown.

However, I have been unable to pinpoint what the exact cause is, it really could be anything, though I would put money on javascript. I disable the javascript that I could (I couldnt do it all as there was dependencies which gave errors) and even upped your jquery (its loading an old version, I have swapped it back for now).

Nothing resolved the issue., It could be that one of the scripts I couldn’t stop from working may be responsible.

There are no obvious jquery errors either.

Right now I would suggest referring to the theme developer for their advice on what could be causing this, though ig there is one available updating the theme may help.


Richard Dean

April 9, 2013 at 7:58 am

Lets say the template company I purchased the template from were less then helpful, I end up downloading a plugin which enables you to create your own custom sidebar and choose what plugins you want to appear on each individual page. Not sure if you would like me to post a link to another developers plugin, so will only post if you think it might benefit other members.

As you can see there is only one calendar now ๐Ÿ™‚ http://themagicbus.com.au/bookings/


Josh

  • Support Staff

April 9, 2013 at 8:02 am

Hi Richard,

Please post a link to the plugin that you found to help with this. We’d all like to what it is.


Richard Dean

April 9, 2013 at 5:16 pm

If you are looking to customize each pages widgets this plugin is great:

http://wordpress.org/extend/plugins/custom-sidebars/


Dean

April 10, 2013 at 5:44 am

Thanks for posting that Richard!

Viewing 27 reply threads

The support post ‘Need some help with ticketing, recurring and calendar’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso