How can i edit $upcomingevents ??

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • aycan555
    Senior Member
    • Jan 2006
    • 137
    • 3.6.x

    How can i edit $upcomingevents ??

    Hi i want to edit the $upcomingevents, does any one know how can i edit this and where?

    Curently it shows the events like:

    Event One, Event Two, Event Three

    I want to change it to:
    Event One,
    Event Two,
    Event Three

    Basickly i want to but each event on new line... ??
  • aycan555
    Senior Member
    • Jan 2006
    • 137
    • 3.6.x

    #2
    Ok lads i have done this thing, but i need to show the costumfields on the forumhome ?? How can i show them next to the event title?

    Comment

    • aycan555
      Senior Member
      • Jan 2006
      • 137
      • 3.6.x

      #3
      Any help pls??

      Comment

      • Steve Machol
        Former Customer Support Manager
        • Jul 2000
        • 154488

        #4
        That's the way they are by default. Try this. Create a new style and choose no parent style. This will force it to use the default templates. Then change to this style and view your forums with it. Do you have the same problem?
        Steve Machol, former vBulletin Customer Support Manager (and NOT retired!)
        Change CKEditor Colors to Match Style (for 4.1.4 and above)

        Steve Machol Photography


        Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.


        Comment

        • aycan555
          Senior Member
          • Jan 2006
          • 137
          • 3.6.x

          #5
          I thıng to show the custom fıeld whıch ı have created. to show them on the forum home ı need to edıt the code below ın the forumroot/ındex.php :

          PHP Code:
            $upcomingevents '';
            foreach(
          $events AS $index => $value)
            {
             
          $pastevent 0;
             
          $pastcount 0;
             
          $comma $eventdates $daysevents '';
             if (!
          $vbulletin->options['showeventtype'])
             { 
          // Group by Event // $index = $eventid
              
          $eventinfo $eventstore["$index"];
              if (empty(
          $eventinfo['recurring']) AND empty($eventinfo['singleday']))
              { 
          // ranged event -- show it from its real start and real end date (vbgmdate)
               
          $fromdate vbdate($vbulletin->options['dateformat'], $eventinfo['dateline_from_user'], falsetruefalsetrue);
               
          $todate vbdate($vbulletin->options['dateformat'], $eventinfo['dateline_to_user'], falsetruefalsetrue);
               if (
          $fromdate != $todate)
               {
                
          $eventdates construct_phrase($vbphrase['event_x_to_y'], $fromdate$todate);
               }
               else
               {
                
          $eventdates vbdate($vbulletin->options['dateformat'], $eventinfo['dateline_from_user'], falsetruefalsetrue);
               }
               
          $day vbdate('Y-n-j'$eventinfo['dateline_from_user'], falsefalse);
              }
              else
              {
               unset(
          $day);
               foreach(
          $value AS $key => $dateline)
               {
                if ((
          $dateline 86400) == $pastevent AND !$eventinfo['holidayid'])
                {
                 
          $pastevent $dateline;
                 
          $pastcount++;
                 continue;
                }
                else
                {
                 if (
          $pastcount)
                 {
                  
          $eventdates construct_phrase($vbphrase['event_x_to_y'], $eventdatesvbdate($vbulletin->options['dateformat'], $pasteventfalsetruefalse));
                 }
                 
          $pastcount 0;
                 
          $pastevent $dateline;
                }
                if (!
          $day)
                {
                 
          $day vbdate('Y-n-j'$datelinefalsefalsefalse);
                }
                
          $eventdates .= $comma vbdate($vbulletin->options['dateformat'], $datelinefalsetruefalse);
                
          $comma ', ';
               }
               if (
          $pastcount)
               {
                
          $eventdates construct_phrase($vbphrase['event_x_to_y'], $eventdatesvbdate($vbulletin->options['dateformat'], $pasteventfalsetruefalse));
               }
              }
              if (
          $eventinfo['holidayid'])
              {
               
          $callink '<a href="calendar.php?' $vbulletin->session->vars['sessionurl'] . "do=getinfo&amp;day=$day\">" $vbphrase['holiday' $eventinfo['holidayid'] . '_title'] . "</a>";
              }
              else
              {
               
          $callink '<a href="calendar.php?' $vbulletin->session->vars['sessionurl'] . "do=getinfo&amp;day=$day&amp;e=$eventinfo[eventid]&amp;c=$eventinfo[calendarid]\">$eventinfo[title]</a>";
              }
             }
             else
             { 
          // Group by Date
              
          $eventdate vbdate($vbulletin->options['dateformat'], $indexfalsetruefalse);
              
          $day vbdate('Y-n-j'$indexfalsefalsefalse);
              foreach(
          $value AS $key => $eventid)
              {
               
          $eventinfo $eventstore["$eventid"];
               if (
          $eventinfo['holidayid'])
               {
                
          $daysevents .= $comma '<a href="calendar.php?' $vbulletin->session->vars['sessionurl'] . "do=getinfo&amp;day=$day\">" $vbphrase['holiday' $eventinfo['holidayid'] . '_title'] . "</a>";
               }
               else
               {
                
          $daysevents .= $comma '<a href="calendar.php?' $vbulletin->session->vars['sessionurl'] . "do=getinfo&amp;day=$day&amp;e=$eventinfo[eventid]&amp;c=$eventinfo[calendarid]\">$eventinfo[title]</a>";
               }
               
          $comma ', ';
              }
             }
             (
          $hook vBulletinHook::fetch_hook('forumhome_event')) ? eval($hook) : false;
             eval(
          '$upcomingevents .= "' fetch_template('forumhome_event') . '";');
            }
            
          // memory saving
            
          unset($events$eventstore);
           }
           
          $show['upcomingevents'] = iif ($upcomingeventstruefalse);
           
          $show['todaysevents'] = iif ($vbulletin->options['showevents'] == 1truefalse);
          }
          else
          {
           
          $show['upcomingevents'] = false;

          But ı dont know what codes ı need to add to call the custom fıeld Any ıdea please ?¿

          Comment

          widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
          Working...
          😀
          😂
          🥰
          😘
          🤢
          😎
          😞
          😡
          👍
          👎