Jump to content

Simsonite

Members
  • Posts

    49
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

Simsonite's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. I used this tutorial and i added the database connection and event parsing etc. You should be able to modify my code to be used on your server but please dont copy my script exactly http://php.about.com/od/finishedphp1/ss/php_calendar.htm
  2. well database connections and some random functions aswell as some session and cookie stuff
  3. ok well in the calendar file you have missed out a ; on line 77. Im guessing that you have some problems with fetching the info from the database.
  4. Can i please have a look at your site?
  5. Yeah my script works, it is a modified version of a tutorial i found somewhere, i can try and find it again if you want. Here is the structure of my database which is generated with phpmyadmin ===Database main == Table structure for table calendar_events |------ |Field|Type|Null|Default |------ |//**id**//|int(11)|Yes|NULL |title|varchar(100)|Yes| |desc|varchar(255)|Yes| |day|int(11)|Yes| |month|int(2)|Yes| |year|int(11)|Yes| |hour|int(11)|Yes| |min|int(11)|Yes| |date|int(11)|Yes| == Dumping data for table calendar_events |1|First Event|This is my First Event|10|3|2009|0|0|1236668400 |2|Second Event|This is my Second Event|5|3|2009|0|0|1236239744 |3|Third Event|This is my Third Event|17|3|2009|0|0|1237334400 |4|Forth Event|This is my Forth Event|10|4|2009|0|0|1239408000 Finally if you want post the structure of your database table and i will see if i can think of a way to create the calendar. Thank you Daniel
  6. actually no this is my events table that holds the events that repeat themselves. Thanks anyway PS. if you think i should remake my calendar from scratch just say.
  7. Hi, I am in the process of developing a calendar application, i have made the basic calendar with events being fetched from a mysql database. However i am slightly confused about how i should modify my script to allow repeat events. I will attach my current file Thank you in advance Daniel [attachment deleted by admin]
  8. Lol but i have only just started and i am trying to find out how the syntax works
  9. I see =) But everybody you have got to realise that i am learning php so please dont get frustrated with me
  10. It comes up with an error for the script you gave me Something is wrong with the $ = 0 Parse error: syntax error, unexpected '=', expecting T_VARIABLE or '$' in /home/____/public_html/login/include/usergroup.php on line 27
  11. HI this code still returns "array" while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) { $array = split(',', "$row[0]"); echo $array; }
  12. Ok that is fixed thanks for that. However how do i split the query i have tried but i just returns "Array"
  13. hmm it is still coming up with the error Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home//////public_html/login/include/usergroup.php on line 23 Here is the code if you need any more info just ask <?php $database['dbserver']="//"; $database['dbuser']="//"; $database['dbname']="//"; $database['dbpass']="//"; $con = mysql_connect($database['dbserver'],$database['dbuser'],$database['dbpass']); mysql_select_db($database['dbname'], $con); /*************************Queries*****************************/ $qgroup = "SELECT CONCAT_WS(',',name) FROM ".TBL_USER_GROUPS." WHERE id IN('1','2','3','4','5','6','7','8') GROUP BY id"; /*************************Results*****************************/ $result = mysql_query($qgroup1, $con); /*************************Variables****************************/ while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) { $array = split(',', "$row"); } echo $array; ?>
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.