Forums / Addon Admin Tools / Scheduled Events Add-On

Scheduled Events Add-On

Views: 45,738

Results 101 to 120 of 232
27 Aug 2010, 10:36 AM
#101
ajhb avatar

ajhb

New Zenner

Join Date:
Jul 2008
Posts:
59
Plugin Contributions:
0

Scheduled Events Add-On

Hi,

Just installed the add-on - seems to work very well - many thanks.

I have a question to take it a step further. I'd like to call the event names and dates into a custom text box on the home page.

I've tried using

<?php include('\includes\templates\orange\templates\tpl_events_home.php');?>

Note I've copied tpl_events_default.php and made tpl_events_home.php in the same directory

I can get text from the file if I add some at the top, (and from a basic php echo 'hello world'), I'm getting nothing from the database. I am not a PHP coder though, just know a few commands.

Does anyone have any ideas. I could be calling the wrong file for starters...

Cheers,
Adam.

27 Aug 2010, 6:36 PM
#102
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,861
Plugin Contributions:
18

Re: Scheduled Events Add-On

When you say text box, are you talking something in one of the sideboxes or a box on the main page?

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

28 Aug 2010, 1:11 AM
#103
ajhb avatar

ajhb

New Zenner

Join Date:
Jul 2008
Posts:
59
Plugin Contributions:
0

Re: Scheduled Events Add-On

Hi,

Sorry, should have been clearer. It'll be a section on the main page (define_main_page.php) where I call in the next 2-3 events from the database.

e.g

SCHEDULED EVENTS

The Peak Open Air Market
2010-09-25

Bradbury School Fair
2010-10-13

   More >>>

Thanks,
Adam.

28 Aug 2010, 1:35 AM
#104
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,861
Plugin Contributions:
18

Re: Scheduled Events Add-On

Okay, I'll take a look later this evening. Out on laptop now.

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

28 Aug 2010, 3:33 AM
#105
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,861
Plugin Contributions:
18

Re: Scheduled Events Add-On

Just a quick look and no guarantees till I can look at it better.

You'll need the $result call out of includes/modules/pages/events/header.php> $result = $db->Execute("SELECT * FROM events WHERE (event_stop >= NOW()-1) ORDER BY event_start");

$eventData = array();
while (!$result->EOF) {
$eventData[] = $result->fields;
$result->MoveNext();
}That will get your data out of the database.

Next, you will need to change> <?php

// Display the text of each event in a paragraph
foreach($eventData as $eventInfo) {
echo "<h5>" . $eventInfo["event_name"] . "</h5><hr />";
echo "<blockquote>";
if ($eventInfo['event_location'] != '') echo "<strong>Place: </strong>" . $eventInfo["event_location"] . "<br />";
if ($eventInfo['event_start'] != '') echo "<strong>Start Date: </strong>" . zen_date_long($eventInfo["event_start"]) . "<br />";
if ($eventInfo['event_stop'] != '') echo "<strong>Stop Date: </strong>" . zen_date_long($eventInfo["event_stop"]) . "<br />";
//if ($eventInfo['Comments'] != '') echo "<strong>Comments: </strong>" . $eventInfo["Comments"] . "<br />";
if ($eventInfo['event_booth_location'] != '') echo "<strong>Booth Location: </strong>" . $eventInfo["event_booth_location"] . "<br />";
if ($eventInfo['special_text'] != '') echo "<strong>Special: </strong>" . $eventInfo["special_text"] . "<br />";
if ($eventInfo['map'] != '') echo "<strong><a href=" . $eventInfo["map"] . ' target="_blank">Driving Directions</a></strong>';
echo "</blockquote><hr />";
}
?>to use for versus foreach and tell it to list however many you want.
Bear in mind that this will bomb if set to 3 and you only have 2 events.
<disclaimer>Not tested and I'm tired from an eleven hour day in the mall.:sleep1:

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

30 Aug 2010, 3:21 AM
#106
ajhb avatar

ajhb

New Zenner

Join Date:
Jul 2008
Posts:
59
Plugin Contributions:
0

Re: Scheduled Events Add-On

Many thanks, was out all day yesterday but will give this a try today and let you know how I get on...

30 Aug 2010, 7:39 AM
#107
ajhb avatar

ajhb

New Zenner

Join Date:
Jul 2008
Posts:
59
Plugin Contributions:
0

Re: Scheduled Events Add-On

Okay, as I suspected my PHP ahem skills are not up to the task...

I understand how tpl_events_default works with regard to displaying the data, so assumed I would be able to call this into another page, in my case 'define_main_page.php', and then simply remove the echo statements for the data I don't want to show.

I then planned to play around with the PHP to try and limit the events to the next 2-3 on the list (which you've kindly provided some code for). But I can't get the basic idea to work.

The page call (include) is working. I'm getting the back button displayed, and PHP is working (I've added an 'echo' to the top of tpl_events_default.php to check this)

Note I've also checked it is working okay when displaying on it's own page (i.e. /index.php?main_page=events) and there is no problem, it looks great (I don't even have to play around with the look of it)!! But I'm having no luck with a call to the DB when trying to diplay it on another page.

So, where am I going wrong in my asumption I can display the same data on another page? Is it something to do with paths??? :blush:

Cheers,
Adam.

define_main_page.php

<?php include('\includes\templates\orange\templates\tpl_events_default.php');?>
4 Oct 2010, 5:52 PM
#108
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,861
Plugin Contributions:
18

Re: Scheduled Events Add-On

NOTE TO ALL USERS:

We are redoing this mod to make it less invasive of the core files and give two options for installation.

Meanwhile... The mod is working with at least 1.3.9f BUT has a small php 5.3 problem that can be fixed by overwriting the phpMyEdit.class.php file in the root directory you are using for your events.

Extract the zip and load the file to the directory you are using for events.

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

11 Nov 2010, 11:09 PM
#109
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Scheduled Events Add-On

This might be EXACTLY what the doctor ordered.. Got a potential client that we are contemplating how to use Zen Cart as an events manager tool (Collect RSVPS and payments).. This add-on might be JUST the tool we need to complete this.. Can't wait to see the new version!!

dbltoe:

NOTE TO ALL USERS:

We are redoing this mod to make it less invasive of the core files and give two options for installation.

Meanwhile... The mod is working with at least 1.3.9f BUT has a small php 5.3 problem that can be fixed by overwriting the phpMyEdit.class.php file in the root directory you are using for your events.

Extract the zip and load the file to the directory you are using for events.

My Site - Zen Cart & WordPress integration specialist
I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

14 Jan 2011, 9:42 PM
#110
antoniog avatar

antoniog

New Zenner

Join Date:
Jan 2011
Location:
Pietrasanta - Lucca - ITALY
Posts:
8
Plugin Contributions:
0

Re: Scheduled Events Add-On

Good add-on!
The installation is complete now and runs well.
Congrats on the link to Google Maps. Very useful for those who create events in a professional manner.
There is a small error message above the table eventz I reach http://locahlost/eshop/eventz and is:

Deprecated: Function set_magic_quotes_runtime() is deprecated in C:\server\www\myserver.dev\public_html\eshop\eventz\phpMyEdit.class.php on line 3100

I do not wish to speak on the function set_magic_quotes_runtime() because I see it just me being the administrator of the shop.

It is now installed on my laptop on the development site where I'm learning about Zen-Cart and where can I test and add add-ons or modules before installing them in the store.
Thanks. I am every day more pleased to have chosen Zen-Cart.

16 Mar 2011, 6:48 PM
#111
soxophoneplayer avatar

soxophoneplayer

Totally Zenned

Join Date:
Feb 2008
Posts:
534
Plugin Contributions:
0

Re: Scheduled Events Add-On

I'm on zc 3.9h I installed this mod back in 3.7 and have updated several times. At zc 3.9d this mod was still working for me. At 3.9h it works on the store front side, but I can no longer access the admin screen of this mod. I hadn't noticed as I only checked it from the store side when I updated....now just discovered the prob as I went to update the coming year's events.

I can access it in my test site but not in live site. I don't have .htaccess file on my test site (windows7 wamp localhost) so I wonder if there is something I should add to my live .htaccess..... or if its more complicated than that (I note comment above that the mod is being re-written.)

I did update the phpMyEdit.class.php from the above zip.

Thanks,
Doug
https://www.meafordwool.com

16 Mar 2011, 7:35 PM
#112
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Scheduled Events Add-On

I've just read through this thread for the first time and see that you are in the process of updating the mod (as of last October).
There are a couple of comments I had from the old posts, which you may already be addressing, but I'll mention them here just in case they help.

You discussed providing pre-edited language files versus giving instructions for adding defines to them. I think it would be simpler and safer all around to add new files for the mod's defines (in the /extra_definitions/ folder), rather than either of the above. Also, moving all output text to language define files as you mentioned is definitely the way to go.

The fix for db table prefixes:
$result = $db->Execute("SELECT * FROM (DB_PREFIX . 'events') WHERE (EndDate >= NOW()-1) ORDER BY StartDate");
might better be done in the ZC standard way, by defining TABLE_EVENTS in a new (extra_datafiles) file and using that. This would even allow the user to change the table's name if they want to, without getting deep into the PHP code.
$result = $db->Execute("SELECT * FROM " . TABLE_EVENTS . " WHERE (EndDate >= NOW()-1) ORDER BY StartDate");

16 Mar 2011, 7:55 PM
#113
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,861
Plugin Contributions:
18

Re: Scheduled Events Add-On

soxophoneplayer:

I did update the phpMyEdit.class.php from the above zip.
I'm curious about this as the file has not changed from the original release to the current version on their website.
What other mods are you using and where did you get your template?

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

16 Mar 2011, 8:37 PM
#114
soxophoneplayer avatar

soxophoneplayer

Totally Zenned

Join Date:
Feb 2008
Posts:
534
Plugin Contributions:
0

Re: Scheduled Events Add-On

I'm curious about this as the file has not changed from the original release to the current version on their website.
What other mods are you using and where did you get your template?

I just noticed that the file had a more recent date than the 2009 file already existing.

I'm using a load of mods, and the template is my own modified version of Classic. The add ons includle Canada Post, Stock by Attribute, Attributes Grid, Product Short Description, IH2, Zen Lightbox, French Pak, Column Grid, Horizontal Dropdown Menu (that I added link for Eventz), Google Analytics, Comodo Trust, Sales Report, Ceon Manual Card, XML Sitemap, About Us, Encrypted Master Password.

When I updated from zc 1.3.9d I eliminated FEC, and Superorders. I added Edit Orders and Ceon SEO.

I am certain that the front end of Events was working after the update to 1.3.9h, but I honestly don't recall if I checked the admin side - but for sure I haven't added any events since the update.

I don't have Ceon SEO on my test site, and I don't have the .htaccess on it, as in both cases it wouldn't work. Everything else is on the test site which I routinely use to test any site modifications before moving them live.

On the test site, the admin worked today but gave an error message on top of the admin page. When I unziped phpMyEdit.class.php and then that error doesn't show anymore. So I then ftp'd that file to my live site to see if it made a difference, and it doesn't.

When trying to get into the eventz admin I get a 'page does not exist' error and it loads my site map.

There is no error showing in the debug cache.

16 Mar 2011, 8:47 PM
#115
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,861
Plugin Contributions:
18

Re: Scheduled Events Add-On

@glen -- yep already working that way. Oct to April is our big on the road time plus I broke an ankle in three places in Dec. Just out of the cast last week. Most of my time has been spent with a leg up in the air.

@sox make sure you uploaded the folder to your root (step 5 of the Basic/Beginner Installation Instructions in the events_installation_users_guide.txt).

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

16 Mar 2011, 9:06 PM
#116
soxophoneplayer avatar

soxophoneplayer

Totally Zenned

Join Date:
Feb 2008
Posts:
534
Plugin Contributions:
0

Re: Scheduled Events Add-On

@sox make sure you uploaded the folder to your root (step 5 of the Basic/Beginner Installation Instructions in the events_installation_users_guide.txt).

Yes, Eventz folder is in public_html folder, which is where my admin folder, includes, etc etc. are located.

12 Aug 2011, 2:56 PM
#117
bamaplants avatar

bamaplants

New Zenner

Join Date:
Aug 2011
Location:
Southern Alabama
Posts:
15
Plugin Contributions:
0

Re: Scheduled Events Add-On

I haven't seen any motion on this thread in awhile.. I am hoping that is not bad news for me.. lol

I am a new zenner and am real interested in this add on... would solve alot of issues I have... anyway.. I am using 1.3.9h and I see it will work with this version..

I do see a couple people asking if there is any way to show scheduled events to non logged in folks on site.. That is MY thing too..

I am going to allow folks to order w/out registering.. and would like those folks to see the schedule as well as I am allowing COD to any of my Live sales events which I would need to list..

thanks for any help or input

Ken

12 Aug 2011, 6:28 PM
#118
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,861
Plugin Contributions:
18

Re: Scheduled Events Add-On

You can blame the lack of traffic on me. Procrastination, a broken ankle, and hand surgery have really messed with my plans for the past year. Barely had time to keep our customers updated.
I had wanted to migrate all of the mod into the admin and database.
Was part way there, but the release of 1.5.0 [BETA] has convinced me that I need to just fix the current for 1.3.9h and go back to the other idea when 1.5.0 is stable.
The mod has never required that a customer be logged in to see the events.
Give me a couple of days to repackage what we have working on 1.3.9h and I will post the zip here.
THANX for the patience.

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

12 Aug 2011, 6:37 PM
#119
bamaplants avatar

bamaplants

New Zenner

Join Date:
Aug 2011
Location:
Southern Alabama
Posts:
15
Plugin Contributions:
0

Re: Scheduled Events Add-On

NO problem... It may be the examples I have seen posted That made me think it could not be seen except by logged in user as I could not find it and wasn't willing to register just to see it.. LMAO I can be a goof..

and shoot man that was a plenty fast reply for me and I look forward to seeing what you have and thanks again

Ken

12 Aug 2011, 7:54 PM
#120
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,861
Plugin Contributions:
18

Re: Scheduled Events Add-On

Maybe the drug fog is lifting as it was pretty easy to repackage for 1.3.9h. And, it will work with 1.5.0 [BETA] as well.

I still want to get rid of the eventz folder in favor of admin manipulation of the database, but that will have to wait.

The zip is too big to attach so, until it's available in the Free Software Add Ons, you can download the file here.

Just in case I only mentioned it 100 times in the readme.....
BACKUP
BACKUP
BACKUP

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com