cucocreative
Forum Replies Created
-
thank rollinwaves, that worked for me.
Got it working with the solution from the other blog (see above post).
This was the conditional statement:
function filterEventOutputCondition($replacement, $condition, $match, $EM_Event){
if (is_object($EM_Event)) {
switch ($condition) {
// #_ATT{Premium}
case 'has_att_premium':
if (is_array($EM_Event->event_attributes) && !empty($EM_Event->event_attributes['Premium']))
$replacement = preg_replace('/\{\/?has_att_premium\}/', '', $match);
else
$replacement = '';
break;
}
}
return $replacement;
}
add_filter('em_event_output_condition', 'filterEventOutputCondition', 10, 4);
Then added this to the formatting field:
{has_att_premium}
<p><span class="hideMe">#_ATT{Premium}</span></p>
<span class="arrow">More</span>
{/has_att_premium}
Nope, that’s not going to work, as I need to link to specific days from the calendar which will bypass that template. So having to go back to plan A.
I did find a more easily understandable explanation about conditional placeholders, here: https://snippets.webaware.com.au/snippets/events-manager-conditional-placeholders-for-custom-attributes
but I can’t get that code to work, you can see my comment at the bottom of that post.
Hmmm that way seems the simplest solution. Just need to figure out how to get the start/end times custom field names into the std WP loop…
thanks again, but not quite what I need. I can add the button but I need it to show conditionally, ie only on some events.
As events really are a custom post and use custom fields, I think it will be easier to just write my own events listing page template using default WP Loop. That might be quicker in the long run.
@angelonwl Thanks, but that seems to be about a different issue. I want to display the #_EVENTURL only on some of the events (within the events listing page) dependent on whether a custom field has data or is empty.
thanks for that link, but it not enough of “an idiots guide” for me. I’m not that hot on php unless it’s really spelt out for me.
I found this page earlier but was unable to untangle/understand to code enough to use it for my purpose. What do I need to swop out with my custom field, or is it more complex than that?
Forum: Plugins
In reply to: [Pricing Table] [Plugin: Pricing Table] ProblemsBecause of these, and I didn’t have the time to find fix, I ended up purchasing “CSS3 Web Pricing Tables Grids For WordPress” from Codecanyon for $15. It is a more polished plugin although it doesn’t just custom posts to manage the tables.
Forum: Themes and Templates
In reply to: Horizontal sub-menu navigation not working in IE8This seems to be a glitch in the way that my version of IE8 renders the css in my version of Parallels 6.0. I have been told that it renders correctly on a real PC and in someone elses version of Parallels in the standalone IE8 and in IETester?
Although IE still can’t handle the transparency code:
filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#CCFFFFFF, endColorstr=#CCFFFFFF);
so I have stripped that out and IE just fallsback to a solid.Forum: Themes and Templates
In reply to: Horizontal sub-menu navigation not working in IE8All I can think of it has something to do with a visibility, position or display css tag applied to some element somewhere
Forum: Themes and Templates
In reply to: Horizontal sub-menu navigation not working in IE8I’ve now stripped out all the background colour, to the navigation, and the text is still hidden, until you click then it displays…
Forum: Themes and Templates
In reply to: Horizontal sub-menu navigation not working in IE8That doesn’t work either. The only thing that works is manually unchecking that style in IE’s dev tools:
filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#CCFFFFFF, endColorstr=#CCFFFFFF);
If I just don’t include that line it still doesn’t work???
I have now stripped out all the transparency and it is still not working, so it’s nothing to do with the css transparency coding.
Forum: Themes and Templates
In reply to: Horizontal sub-menu navigation not working in IE8I have point-pointed the problem.
On the first level of the navigation is the css:
background: rgb(217, 217, 217) transparent;
background: rgba(255, 255, 255, 0.8);
filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#CCFFFFFF, endColorstr=#CCFFFFFF);
-ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#CCFFFFFF, endColorstr=#CCFFFFFF)";to add transparency to the top level navigation. I might have to revert to using a png background instead of css.
Forum: Themes and Templates
In reply to: .js files only load when I am logged into wordpress adminRight, found some time to sort this out.
I added:
function my_init() { if (!is_admin()) { // comment out the next two lines to load the local copy of jQuery wp_deregister_script('jquery'); wp_register_script('jquery', 'https://www.cucocreative.co.uk/my_scripts/jquery-1.6.1.min.js', false, '1.6.1'); wp_enqueue_script('jquery'); wp_enqueue_script( 'smoothscroll', 'https://www.cucocreative.co.uk/my_scripts/smoothscroll.js', array('jquery') ); wp_enqueue_script( 'smoothscroll', 'https://www.cucocreative.co.uk/my_scripts/jquery.ImageOverlay.js', array('jquery') ); } }
to my functions file and the scripts are now loading, now I just need to figure out home to make it conditional to only call it on the homepage.
Forum: Themes and Templates
In reply to: .js files only load when I am logged into wordpress adminbut why do 2 JavaScript scripts load but 3 more are not included until you log in?
Plus why has this only just recently become a problem, does WP handle scripts differently now.
I’ll have to google how to write conditional statements to see if that will work.