receiving errors creating events

Hello all,

I seem to be getting errors when i create new events. the error only appears if i don't add a pic to the event otherwise its fine.

running dolphin 6.1.6


Warning: getimagesize() [function.getimagesize]: Filename cannot be empty in /home/inc/classes/BxDolEvents.php on line 252

Warning: Cannot modify header information - headers already sent by (output started at /home/inc/classes/BxDolEvents.php:252) in /home/inc/design.inc.php on line 498

Any ideas how i can fix this?

thanks

Robin

Quote · 16 Jul 2009

Can we please have lines 252 from inc/classes/BxDolEvents.php & line 498.  The entire string would be useful from each section of the file.  That way we can start to see what your seeing, and yes 6.1 has been buggy today, I just had to clear errors out of my compose.php file that dealt with unexpect T errors, so have fun today guys, I think Boonex is just playing with our minds.

Quote · 16 Jul 2009

Hello Mydatery,

Thanks for the reply back..

before i posted the error messages i did remove 2 folder located between home and inc which were present in both lines of error. The reason i removed the 2 folders was for security reasons.

Sorry about the deception but its more like lesson learned.

Quote · 16 Jul 2009

anyone?

Quote · 17 Jul 2009

What files did you remove that is causing this:

 

File name cannot be empty in /home/inc/classes/BxDolEvents.php on line 252

 

If you have a base install then this is what inc/classes/BxDolEvents.php shows for that section of code, line 252 is highlighted:

 

 

// event place
  $sEventCountry = process_db_input( $_POST['event_country'], 1 );
  $sEventCity    = process_db_input( $_POST['event_city'], 1 );
  $EventPlace    = process_db_input( $_POST['event_place'], 1 );
  $sTags    = process_db_input( $_POST['event_tags'], 1 );
  $aTags = explodeTags($sTags);
  $sTags = implode(",", $aTags);

  $sEventPhotoFilename = '';

  if ($_FILES['event_photo']) {
   $sPictureName = $sBaseName;
   $aScan = getimagesize($_FILES['event_photo']['tmp_name']);

   if ( in_array($aScan[2], array(1,2,3,6)) && 0 < strlen( $_FILES['event_photo']['name']) ) {

    $sCurrentTime = time();
    if ($iEventID == -1) {
     $sBaseName = 'g_'. $sCurrentTime .'_1';
    } else {
     $sBaseName = db_value("SELECT `PhotoFilename` FROM `SDatingEvents` WHERE `ID`='{$iEventID}' LIMIT 1");
     if ($sBaseName!="") {
      if (ereg ("([a-z0-9_]+)\.", $sBaseName, $aRegs)) {
       $sBaseName = $aRegs[1];
      }
     } else {
      $sBaseName = ($sBaseName!="") ? $sBaseName : 'g_'. $sCurrentTime .'_1';
     }
    }

    $sExt = moveUploadedImage( $_FILES, 'event_photo', $dir['tmp'] . $sBaseName, '', false );

    $sBaseName .= $sExt;

    $sPictureName = $sBaseName;
    $sThumbName   = 'thumb_'.$sBaseName;
    $sIconName   = 'icon_'.$sBaseName;

 

*****************************************************************************************

 

With that in mind, it appears that you have removed the very folders/files that were supposed to hold the images and thus they have no place to go now.  Put them back and your problem will be solved.  If you can't remember what you deleted, which is a really stupid thing to do, I don't even have to work to demonstrate how stupid it is to allow a 5 year old to conduct a lobotomy, which is what you did.  If you can't remember, then get a fresh install of 6.1.6 and open it on your laptop using your FTP right next to your servers files and go through them one at a time, every part of the tree, until you find what your lower brain removed.

Quote · 17 Jul 2009

Ideas anyone?

No file or folders were deleted.  I removed certain parts of my post in this case the path to the file/folder for security reasons, in this instant i took out 2 folder level /home/folder/folder/inc/design.inc.php before posting it in the forum otherwise its a standard install and upgraded with patch 6.1.16. no mods installed.

everything else works fine, actually some of the ray suite isnt working but i haven't had a chance to research the forum yet...

thank

Quote · 22 Jul 2009

The error only happens if you DON'T upload a picture.

 

okay, open:

 

inc/classes/BxDolEvents.php

 

Locate the following code:

 

    $aScan = getimagesize($_FILES['event_photo']['tmp_name']);

Please look above it and see if you see this:

 if ($_FILES['event_photo']) {
   $sPictureName = $sBaseName;
   $aScan = getimagesize($_FILES['event_photo']['tmp_name']);

 

 

 

If it's not there, then that is your error.  It's using an if command and more than likely your command has an error in it somewhere between if and ); 2 lines below it.  Check the code character by character and this should fix your problem.

 

****Note: The above post has been made the New, Improved, Kinder, Gentler, Polite, Serious Mydatery. No part of this post has been intended to belittle, insult, intimidate, humiliate, bash, bully, scare or harrass any other poster or reader. May the Gods shine down upon the marble heads of all moderations.

Quote · 23 Jul 2009

I had the same problem and fixed this by changing line 250 to:

if ($_FILES['event_photo']['tmp_name']) {

This way it checks the array for the tmp_name variable and only process the image function if it exists.

Quote · 29 Jul 2009

I also got the erro but seen I will upgrade it to Dolphin 7 soon, I'll wait to see if this is corrected with Dolphin 7.

Quote · 24 Oct 2009
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.