Jump to content

mikefrederick

Members
  • Posts

    247
  • Joined

  • Last visited

    Never

Posts posted by mikefrederick

  1. sure, thanks guys. Here is a strange issue: when echo $eventdates[$i][$t]; within the while loop, the dates between the lower and upperbound show up.

    <?php
    
    $se = new StaticEvents();
    
    $events_r = $se->getEvents();
    
    and from that class file:
    
    class StaticEvents {
      function StaticEvents() {
      }
      
      function getEvents() {
        $events = array();
        $events[0]["id"] = "1194660001";
        $events[0]["name"] = "Men's Retreat 1";
        $events[0]["version"] = "7d5e07";
        $events[0]["season"] = "Fall";
        $events[0]["category"] = "Adult";
        $events[0]["date_lbound"] = "2007-11-9 7:00 PM";
        $events[0]["date_ubound"] = "2007-11-11 11:00 AM";
        $events[0]["display"] = "False";
        $events[0]["register"] = "False";
        $events[0]["audience"] = "";
        $events[0]["intro"] = "njoy fall in the mountain";
        $events[1]["id"] = "1195264801";
        $events[1]["name"] = "Mens Retreat 2";
        $events[1]["version"] = "7d5e07";
        $events[1]["season"] = "Fall";
        $events[1]["category"] = "Adult";
        $events[1]["date_lbound"] = "2007-11-16 7:00 PM";
        $events[1]["date_ubound"] = "2007-11-18 11:00 AM";
        $events[1]["display"] = "False";
        $events[1]["register"] = "False";
        $events[1]["audience"] = "";
        $events[1]["intro"] = "njoy fall in the mountain";
    
    
    
    
    etc. ?> 

  2. I am making a calendar, and I have events that have upper and lower bounds. For all dates between those two dates, I want to have the event show up for that day (right now I am writing 'Y' for all dates with events). I can't get the dates between the upper and lower bound to show up with a Y. Thanks for taking a look...

     

     

    <?php
    for($i=0; $i<=30; $i++) {
    
    $lbound=$events_r[$i]["date_lbound"];
    $ubound=$events_r[$i]["date_ubound"];
    $explodelower[$i]=explode(" ",$events_r[$i]["date_lbound"]);
    $explodeupper[$i]=explode(" ",$events_r[$i]["date_ubound"]);
    $start = strtotime($explodelower[$i][0]);
    $end = strtotime($explodeupper[$i][0]);
    $t=0;
    
    while ($start < $end)
    {
      $eventdates[$i][$t]=date('Y-j-n', $start);
       $t++;
      $start = strtotime("{$lbound} +{$t} days");
    }
    
    }
    //this changes correctly for each date of the year (i.e. march 1, 2008 = 2008-1-3)
    $newdatee=$newyear . "-".$newmonth. "-" . $date;
    
    
    for($r=0; $r<=30; $r++) {
    
    //HELP HERE FOR FIRST CONDITION OF IF STATEMENT IS NEEDED
    if($eventdates[$r]==$newdatee || $explodelower[$r][0]==$newdatee || $explodeupper[$r][0]==$newdatee) {
    echo 'Y';
    }  } ?> 

  3. so i have the following class file. I have never dealt with classes before, how do I echo $events[0]["id"] on a separate page? include it and then what?

     

    <?
    class StaticEvents {
      function StaticEvents() {
      }
      
      function getEvents() {
        $events = array();
        $events[0]["id"] = "1194660001";
        $events[0]["name"] = "Men's Retreat 1";
        $events[0]["version"] = "7d5e07";
        $events[0]["season"] = "Fall";
        $events[0]["category"] = "Adult";
        $events[0]["date_lbound"] = "2007-11-9 7:00 PM";
        $events[0]["date_ubound"] = "2007-11-11 11:00 AM";
        $events[0]["display"] = "False";
        $events[0]["register"] = "False";
        $events[0]["audience"] = "";
        $events[0]["intro"] = "njoy fall in the mountain";
        $events[1]["id"] = "1195264801";
        $events[1]["name"] = "Mens Retreat 2";
        $events[1]["version"] = "7d5e07";
        $events[1]["season"] = "Fall";
        $events[1]["category"] = "Adult";
        $events[1]["date_lbound"] = "2007-11-16 7:00 PM";
        $events[1]["date_ubound"] = "2007-11-18 11:00 AM";
        $events[1]["display"] = "False";
        $events[1]["register"] = "False";
        $events[1]["audience"] = "";
        $events[1]["intro"] = "njoy fall in the mountain";
        $events[2]["id"] = "1197079201";
        $events[2]["name"] = "Youth Workers Retreat";
        $events[2]["version"] = "7d5e07";
        $events[2]["season"] = "Fall";
        $events[2]["category"] = "Adult";
        $events[2]["date_lbound"] = "2007-12-7 7:00 PM";
        $events[2]["date_ubound"] = "2007-12-9 11:00 AM";
        $events[2]["display"] = "False";
        $events[2]["register"] = "Disabled";
        $events[2]["audience"] = "Youth Workers";
        $events[2]["intro"] = "ome for a weekend with so";
        $events[3]["id"] = "1199498401";
        $events[3]["name"] = "Deep Freeze Jr. & Sr. (Jan 4-6) CALL OFFICE";
        $events[3]["version"] = "7d5e01";
        $events[3]["season"] = "Winter";
        $events[3]["category"] = "Youth";
        $events[3]["date_lbound"] = "2008-1-4 7:00 PM";
        $events[3]["date_ubound"] = "2008-1-6 1:00 PM";
        $events[3]["display"] = "True";
        $events[3]["register"] = "Phone Only";
        $events[3]["audience"] = "Jr. & Sr. High Youth Groups";
        $events[3]["intro"] = "he world has a lot to say";
        $events[4]["id"] = "1168567202";
        $events[4]["name"] = "Deep Freeze Jr. & Sr. (Jan 11-13) CALL OFFICE";
        $events[4]["version"] = "7d5e01";
        $events[4]["season"] = "Winter";
        $events[4]["category"] = "Youth";
        $events[4]["date_lbound"] = "2008-1-11 7:00 PM";
        $events[4]["date_ubound"] = "2008-1-13 1:00 PM";
        $events[4]["display"] = "True";
        $events[4]["register"] = "Phone Only";
        $events[4]["audience"] = "Jr. & Sr. High Youth Groups";
        $events[4]["intro"] = "he world has a lot to say";
        $events[5]["id"] = "1169172001";
        $events[5]["name"] = "Deep Freeze Jr. & Sr. (Jan 18-20)";
        $events[5]["version"] = "7d5e01";
        $events[5]["season"] = "Winter";
        $events[5]["category"] = "Youth";
        $events[5]["date_lbound"] = "2008-1-18 7:00 PM";
        $events[5]["date_ubound"] = "2008-1-20 1:00 PM";
        $events[5]["display"] = "True";
        $events[5]["register"] = "Open";
        $events[5]["audience"] = "Jr. & Sr. High Youth Groups";
        $events[5]["intro"] = "he world has a lot to say";
        $events[6]["id"] = "1169776801";
        $events[6]["name"] = "Deep Freeze Jr. & Sr. (Jan 25-27) ";
        $events[6]["version"] = "7d5e01";
        $events[6]["season"] = "Winter";
        $events[6]["category"] = "Youth";
        $events[6]["date_lbound"] = "2008-1-25 7:00 PM";
        $events[6]["date_ubound"] = "2008-1-27 1:00 PM";
        $events[6]["display"] = "True";
        $events[6]["register"] = "Open";
        $events[6]["audience"] = "Youth Groups";
        $events[6]["intro"] = "he world has a lot to say";
        $events[7]["id"] = "1201917601";
        $events[7]["name"] = "Deep Freeze Jr. High (Feb 1-3) ";
        $events[7]["version"] = "7d5e01";
        $events[7]["season"] = "Winter";
        $events[7]["category"] = "Youth";
        $events[7]["date_lbound"] = "2008-2-1 7:00 PM";
        $events[7]["date_ubound"] = "2008-2-3 1:00 PM";
        $events[7]["display"] = "True";
        $events[7]["register"] = "Open";
        $events[7]["audience"] = "Youth Groups";
        $events[7]["intro"] = "he world has a lot to say";
        $events[8]["id"] = "1202522401";
        $events[8]["name"] = "Deep Freeze Jr. & Sr. (Feb 8-10) CALL OFFICE";
        $events[8]["version"] = "7d5e01";
        $events[8]["season"] = "Winter";
        $events[8]["category"] = "Youth";
        $events[8]["date_lbound"] = "2008-2-8 7:00 PM";
        $events[8]["date_ubound"] = "2008-2-10 1:00 PM";
        $events[8]["display"] = "True";
        $events[8]["register"] = "Phone Only";
        $events[8]["audience"] = "Youth Groups";
        $events[8]["intro"] = "he world has a lot to say";
        $events[9]["id"] = "1203127201";
        $events[9]["name"] = "Deep Freeze Jr. & Sr. (Feb 15-17) CALL OFFICE";
        $events[9]["version"] = "7d5e01";
        $events[9]["season"] = "Winter";
        $events[9]["category"] = "Youth";
        $events[9]["date_lbound"] = "2008-2-15 7:00 PM";
        $events[9]["date_ubound"] = "2008-2-17 1:00 PM";
        $events[9]["display"] = "True";
        $events[9]["register"] = "Phone Only";
        $events[9]["audience"] = "Youth Groups";
        $events[9]["intro"] = "he world has a lot to say";
        $events[10]["id"] = "1203732001";
        $events[10]["name"] = "Deep Freeze Sr. High and Jr. High!  (Feb 22-24)";
        $events[10]["version"] = "7d5e01";
        $events[10]["season"] = "Winter";
        $events[10]["category"] = "Youth";
        $events[10]["date_lbound"] = "2008-2-22 7:00 PM";
        $events[10]["date_ubound"] = "2008-2-24 1:00 PM";
        $events[10]["display"] = "True";
        $events[10]["register"] = "Open";
        $events[10]["audience"] = "Youth Groups";
        $events[10]["intro"] = "he world has a lot to say";
        $events[11]["id"] = "1204336801";
        $events[11]["name"] = "Deep Freeze Jr. & Sr. (Feb 29-Mar 2) CALL OFFICE";
        $events[11]["version"] = "7d5e01";
        $events[11]["season"] = "Winter";
        $events[11]["category"] = "Youth";
        $events[11]["date_lbound"] = "2008-2-29 7:00 PM";
        $events[11]["date_ubound"] = "2008-3-2 1:00 PM";
        $events[11]["display"] = "True";
        $events[11]["register"] = "Phone Only";
        $events[11]["audience"] = "Youth Groups";
        $events[11]["intro"] = "he world has a lot to say";
        $events[12]["id"] = "1204941601";
        $events[12]["name"] = "Deep Freeze Jr. & Sr. (Mar 7-9) CALL OFFICE";
        $events[12]["version"] = "7d5e01";
        $events[12]["season"] = "Winter";
        $events[12]["category"] = "Youth";
        $events[12]["date_lbound"] = "2008-3-7 7:00 PM";
        $events[12]["date_ubound"] = "2008-3-9 1:00 PM";
        $events[12]["display"] = "True";
        $events[12]["register"] = "Phone Only";
        $events[12]["audience"] = "Youth Groups";
        $events[12]["intro"] = "he world has a lot to say";
        $events[13]["id"] = "1205546401";
        $events[13]["name"] = "Deep Freeze Jr. & Sr. (Mar 14-16)";
        $events[13]["version"] = "7d5e01";
        $events[13]["season"] = "Winter";
        $events[13]["category"] = "Youth";
        $events[13]["date_lbound"] = "2008-3-14 7:00 PM";
        $events[13]["date_ubound"] = "2008-3-16 1:00 PM";
        $events[13]["display"] = "True";
        $events[13]["register"] = "Open";
        $events[13]["audience"] = "Youth Groups";
        $events[13]["intro"] = "he world has a lot to say";
        $events[14]["id"] = "1210384801";
        $events[14]["name"] = "Mother/Daughter Retreat";
        $events[14]["version"] = "7d5e03";
        $events[14]["season"] = "Spring";
        $events[14]["category"] = "Family";
        $events[14]["date_lbound"] = "2008-5-9 7:00 PM";
        $events[14]["date_ubound"] = "2008-5-11 11:00 AM";
        $events[14]["display"] = "True";
        $events[14]["register"] = "True";
        $events[14]["audience"] = "Mothers and daughters, ages 5 & up.";
        $events[14]["intro"] = "et away and devote an ent";
        $events[15]["id"] = "1212804001";
        $events[15]["name"] = "Father/Son Retreat";
        $events[15]["version"] = "7d5e03";
        $events[15]["season"] = "Spring";
        $events[15]["category"] = "Family";
        $events[15]["date_lbound"] = "2008-6-6 7:00 PM";
        $events[15]["date_ubound"] = "2008-6-8 11:00 AM";
        $events[15]["display"] = "True";
        $events[15]["register"] = "True";
        $events[15]["audience"] = "Fathers and Sons ages 5 & up";
        $events[15]["intro"] = "evote some quality time c";
        $events[16]["id"] = "1214168401";
        $events[16]["name"] = "Primary/Junior Camp";
        $events[16]["version"] = "7d5e05";
        $events[16]["season"] = "Summer";
        $events[16]["category"] = "Youth";
        $events[16]["date_lbound"] = "2008-6-22 2:00 PM";
        $events[16]["date_ubound"] = "2008-6-28 11:00 AM";
        $events[16]["display"] = "True";
        $events[16]["register"] = "Open";
        $events[16]["audience"] = "Co-ed (completed 2nd thru 5th)";
        $events[16]["intro"] = "our young camper will jum";
        $events[17]["id"] = "1214773201";
        $events[17]["name"] = "Jr./Sr. High Camp";
        $events[17]["version"] = "7d5e05";
        $events[17]["season"] = "Summer";
        $events[17]["category"] = "Youth";
        $events[17]["date_lbound"] = "2008-6-29 2:00 PM";
        $events[17]["date_ubound"] = "2008-7-5 11:00 AM";
        $events[17]["display"] = "True";
        $events[17]["register"] = "Open";
        $events[17]["audience"] = "";
        $events[17]["intro"] = "ake the chance to build l";
        $events[18]["id"] = "1215378001";
        $events[18]["name"] = "Boys' Camp";
        $events[18]["version"] = "7d5e05";
        $events[18]["season"] = "Summer";
        $events[18]["category"] = "Youth";
        $events[18]["date_lbound"] = "2008-7-6 2:00 PM";
        $events[18]["date_ubound"] = "2008-7-12 1:00 AM";
        $events[18]["display"] = "True";
        $events[18]["register"] = "True";
        $events[18]["audience"] = "Boys (completed 4th thru 8th grade)";
        $events[18]["intro"] = "oys, this is non-stop exc";
        $events[19]["id"] = "1167703202";
        $events[19]["name"] = "Jr. High #1 Camp";
        $events[19]["version"] = "7d5e05";
        $events[19]["season"] = "Summer";
        $events[19]["category"] = "Youth";
        $events[19]["date_lbound"] = "2008-7-13 2:00 PM";
        $events[19]["date_ubound"] = "2008-7-19 1:00 AM";
        $events[19]["display"] = "True";
        $events[19]["register"] = "True";
        $events[19]["audience"] = "Co-ed (completed 6th thru 8th grade)";
        $events[19]["intro"] = "ickin'!  This sweet week";
        $events[20]["id"] = "1216587601";
        $events[20]["name"] = "Girl's Camp";
        $events[20]["version"] = "7d5e05";
        $events[20]["season"] = "Summer";
        $events[20]["category"] = "Youth";
        $events[20]["date_lbound"] = "2008-7-20 2:00 PM";
        $events[20]["date_ubound"] = "2008-7-26 1:00 AM";
        $events[20]["display"] = "True";
        $events[20]["register"] = "True";
        $events[20]["audience"] = "Girls (completed 4th - 8th grade)";
        $events[20]["intro"] = "ear not - no annoying boy";
        $events[21]["id"] = "1167703203";
        $events[21]["name"] = "Senior High Camp";
        $events[21]["version"] = "7d5e05";
        $events[21]["season"] = "Summer";
        $events[21]["category"] = "Youth";
        $events[21]["date_lbound"] = "2008-7-27 2:00 PM";
        $events[21]["date_ubound"] = "2008-8-2 1:00 AM";
        $events[21]["display"] = "True";
        $events[21]["register"] = "Open";
        $events[21]["audience"] = "Co-ed (completed 9th thru 12th grade)";
        $events[21]["intro"] = "ake the chance to build l";
        $events[22]["id"] = "1217797201";
        $events[22]["name"] = "Jr. High #2 Camp";
        $events[22]["version"] = "7d5e05";
        $events[22]["season"] = "Summer";
        $events[22]["category"] = "Youth";
        $events[22]["date_lbound"] = "2008-8-3 2:00 PM";
        $events[22]["date_ubound"] = "2008-8-9 1:00 AM";
        $events[22]["display"] = "True";
        $events[22]["register"] = "Open";
        $events[22]["audience"] = "Co-ed (completed 6th thru 8th grade)";
        $events[22]["intro"] = "ickin'!  This sweet week";
        $events[23]["id"] = "1218315601";
        $events[23]["name"] = "Family Week #1";
        $events[23]["version"] = "7d5e03";
        $events[23]["season"] = "Late Summer";
        $events[23]["category"] = "Family";
        $events[23]["date_lbound"] = "2008-8-9 2:00 PM";
        $events[23]["date_ubound"] = "2008-8-15 1:00 AM";
        $events[23]["display"] = "True";
        $events[23]["register"] = "Phone Only";
        $events[23]["audience"] = "Couples and Familes";
        $events[23]["intro"] = "amily Camp carries on the";
        $events[24]["id"] = "1167703204";
        $events[24]["name"] = "Family Week #2";
        $events[24]["version"] = "7d5e03";
        $events[24]["season"] = "Late Summer";
        $events[24]["category"] = "Family";
        $events[24]["date_lbound"] = "2008-8-16 2:00 PM";
        $events[24]["date_ubound"] = "2008-8-22 1:00 AM";
        $events[24]["display"] = "True";
        $events[24]["register"] = "Phone Only";
        $events[24]["audience"] = "Couples and Familes";
        $events[24]["intro"] = "amily Camp carries on the";
        $events[25]["id"] = "1219456801";
        $events[25]["name"] = "Ignite #1";
        $events[25]["version"] = "7d5e01";
        $events[25]["season"] = "Late Summer";
        $events[25]["category"] = "Youth";
        $events[25]["date_lbound"] = "2008-8-22 7:00 PM";
        $events[25]["date_ubound"] = "2008-8-24 1:00 PM";
        $events[25]["display"] = "True";
        $events[25]["register"] = "Open";
        $events[25]["audience"] = "Jr. & Sr. High Youth Groups";
        $events[25]["intro"] = "magine this...a whole wee";
        $events[26]["id"] = "1220666401";
        $events[26]["name"] = "Ignite #2";
        $events[26]["version"] = "7d5e01";
        $events[26]["season"] = "Late Summer";
        $events[26]["category"] = "Youth";
        $events[26]["date_lbound"] = "2008-9-5 7:00 PM";
        $events[26]["date_ubound"] = "2008-9-7 1:00 PM";
        $events[26]["display"] = "True";
        $events[26]["register"] = "True";
        $events[26]["audience"] = "Jr. & Sr. High Youth Groups";
        $events[26]["intro"] = "magine this...a whole wee";
        $events[27]["id"] = "1167703205";
        $events[27]["name"] = "Women's Retreat #1";
        $events[27]["version"] = "7d5e07";
        $events[27]["season"] = "Fall";
        $events[27]["category"] = "Adult";
        $events[27]["date_lbound"] = "2008-9-19 7:00 PM";
        $events[27]["date_ubound"] = "2008-9-21 1:00 PM";
        $events[27]["display"] = "True";
        $events[27]["register"] = "True";
        $events[27]["audience"] = "";
        $events[27]["intro"] = "";
        $events[28]["id"] = "1222480801";
        $events[28]["name"] = "Women's Retreat #2";
        $events[28]["version"] = "7d5e07";
        $events[28]["season"] = "Fall";
        $events[28]["category"] = "Adult";
        $events[28]["date_lbound"] = "2008-9-26 7:00 PM";
        $events[28]["date_ubound"] = "2008-9-28 1:00 PM";
        $events[28]["display"] = "True";
        $events[28]["register"] = "True";
        $events[28]["audience"] = "";
        $events[28]["intro"] = "";
        $events[29]["id"] = "1226714401";
        $events[29]["name"] = "Men's Retreat 1";
        $events[29]["version"] = "7d5e07";
        $events[29]["season"] = "Fall";
        $events[29]["category"] = "Adult";
        $events[29]["date_lbound"] = "2008-11-14 7:00 PM";
        $events[29]["date_ubound"] = "2008-11-16 11:00 AM";
        $events[29]["display"] = "True";
        $events[29]["register"] = "True";
        $events[29]["audience"] = "";
        $events[29]["intro"] = "";
        $events[30]["id"] = "1227319201";
        $events[30]["name"] = "Men's Retreat 2";
        $events[30]["version"] = "7d5e07";
        $events[30]["season"] = "Fall";
        $events[30]["category"] = "Adult";
        $events[30]["date_lbound"] = "2008-11-21 7:00 PM";
        $events[30]["date_ubound"] = "2008-11-23 11:00 AM";
        $events[30]["display"] = "True";
        $events[30]["register"] = "True";
        $events[30]["audience"] = "";
        $events[30]["intro"] = "";
        return $events;
      }
    }
    ?>
    

  4. Thanks ahead of time:

     

    If I have two dates , say February 28, 2008 and March 28, 2008, how can I echo every date between them? I supposed I could calculate the difference between the two and do for($day=0, $day<=$difference, $day++) and then do a day+$i type of thing, any other suggestions?

  5. Thanks a lot if you can help with this. My script for chained select boxes works all the time other than in IE. in IE, it only repopulates the second box certain times. I am populating from databases. I can't figure it out....

    See them at ivoiresondage.com/index.php.

     

    important script in header :

    function getCountries(sel)
    {
    var countryCode = sel.options[sel.selectedIndex].id;
    var rid = sel.options[sel.selectedIndex].value;
    document.getElementById('dhtmlgoodies_country').options.length = 0;	// Empty city select box
    if(countryCode.length>0){
    
    	var index = ajax.length;
    	ajax[index] = new sack();
    
    	ajax[index].requestFile = 'populate.php?rid='+rid+'&countryCode='+countryCode;	// Specifying which file to get
    	ajax[index].onCompletion = function(){ createCountries(index) };	// Specify function that will be executed after file has been found
    	ajax[index].runAJAX();		// Execute AJAX function
    }
    }
    
    function createCountries(index)
    {
    var obj = document.getElementById('dhtmlgoodies_country');
    eval(ajax[index].response);	// Executing the response from Ajax as Javascript code	
    }

     

     

     

    Associated files:

    -ivoiresondage.com/ajax.js

    -ivoiresondage.com/populate.php.

    code for populate.php:

    <?php
    
    include "config.php";
    $action=$_GET["countryCode"];
    switch($action)
    {
    case "getcountries":
    	$rid=$_REQUEST["rid"];
    	$sql="select * from departments where rid='$rid' order by name";
    	$res=mysql_query($sql);
    	$y.="obj.options[obj.options.length] = new Option('...','...');\n";
    	while($row=mysql_fetch_array($res))
    	{
    		$y.="obj.options[obj.options.length] = new Option('$row[name]','$row[id]');\n";
    
    	}
    
    	echo $y;	break;
    
    
    }
    
    
    $actionz=$_REQUEST["category"];
    switch($actionz)
    {
    
    case "test":
    $cid=$_GET["cid"];
    	$sqltt="select * from departments where rid='$rid' order by name";
    	$restt=mysql_query($sqltt);
    
    	$out.="obj.options[obj.options.length] = new Option('Select a State','1');\n";
    	while($rowtt=mysql_fetch_array($restt))
    	{
    		$out.="obj.options[obj.options.length] = new Option('$rowtt[name]','$rowtt[id]');\n";
    	}
    
    	echo $out;
    break;
    
    }
    
    
    
    
    ?>

     

     

     

     

     

     

  6. I know it's javascript but I didn't want to open an account on a diff site. How do I make the following echo the value of the actual selectedIndex rather than just saying selectedIndex in the url of the window it opens:

     

     

    <select onchange="open_window('departmentvotes.php?id=this.selectedIndex.value')"  name="dept" >

  7. how are you planning on emailing them if you don't know the @domain.ext part of the email address? you need to store the full email address in a database, and then take the email string and replace everything in the email address starting with the @ symbol with "" (nothing) and then make that appear in the drop down box and then make a script to email to that address when the form is submitted. if you don't know anything about php it will take you a while.

  8. Thanks for the help ahead of time anyone.

    I am making a system similar to https://www.myboatsign.com/. The company that I am going to have produce the vinyl lettering says that they need a vector image, so I would like that to be generated automatically. I know there are some php classes out there for this, but I was looking on advice on how to go about doing it before I get started searching through them.  Does anyone know some good classes that can help me or have an example of how I would do such a thing? Thanks.

  9. hoping someone here can help me with actionscript.i dont know actionscript very well, how do i write a variable out in the orange part below...like in php i would have $i=0; and then write out myVar$i but I don't know how to do this with actionscript...the part I am talking about is highlighted in orange below.

     

     

     

    var x=1;

    while(x<20) {

     

     

    var mc:MovieClip = this._parent.triangle1;

    var myLV:LoadVars = new LoadVars();

    myLV.onLoad = function() {

    if (this.myVarx == '2225') {

    var colorful = new Color(mc);

    colorful.setRGB(0x003366);

    }

    else if (this.myVar(i) == '2226') {

    var colorful = new Color(mc);

    colorful.setRGB(0xed4d43);

    }

    else if (this.myVar3 == '2227') {

    var colorful = new Color(mc);

    colorful.setRGB(0x30b123);

    }

    else if (this.myVar3 == '2228') {

    var colorful = new Color(mc);

    colorful.setRGB(0xd4d20f);

    }

    else if (this.myVar3 == '2229') {

    var colorful = new Color(mc);

    colorful.setRGB(0xffdd22);

    }

    else if (this.myVar3 == '2230') {

    var colorful = new Color(mc);

    colorful.setRGB(0xcc0aca);

    }

    else if (this.myVar3 == '2231') {

    var colorful = new Color(mc);

    colorful.setRGB(0xff7ed9);

    }

     

    trace(this.myVar3);

    };

    x++;

    }

  10. So I have this query, and basically for each departmentid I need to select the answerid that occurs the most times for that departmentid. Then, at the end I need to tally up how many times an answerid showed up (so if an answerid occurred the most for 2 different departmentid's then this would equal 2). How could I do this? Thanks ahead of time.

     

    $query = "SELECT COUNT(*) as votecount, candidates.id as c_id, candidates.name as c_name,
                     departments.id as d_id, departments.name as d_name
              FROM newvotes
                JOIN candidates ON newvotes.answerid = candidates.id
                JOIN departments ON newvotes.departmentid = departments.id
              GROUP BY  candidates.id, departments.id
              ORDER BY departments.id";
    

  11. i understand what xss is and i have done it before and am looking on clarification on how to prevent it...should I never echo any $_GET variables in a page and instead put them in a mysql_query when possible or what?

×
×
  • 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.