Support > General Support

Errors installing

(1/2) > >>

porsch:
I have just installed SMF 1.07 and want to add the Ad Management Package. I've download the zip file and uploaded the package. When I go to install the mod I get the following error message:

2: fopen(): SAFE MODE Restriction in effect. The script whose uid is 10007 is not allowed to access /var/www/vhosts/abitofchatter.com/httpdocs/forum/Packages/temp owned by uid 48
File: /var/www/vhosts/abitofchatter.com/httpdocs/forum/Sources/Subs-Package.php
Line: 1476

Is there a manual way of installing the package?

bigguy:
Look in the install.xml file for all the edits so you can do it manually.

porsch:
I think the first problem I need to solve is to get the files on my server. All I've got right now is a zip file sitting in my Packages folder. What files and where should be on my host so that I can try the mods. Sorry if I am sounding dumb but I'm still trying to figure my way around on how SMF works.

bigguy:
Open the install.xml file on your desktop and it will have all the edits in it. There shuldn`t be any files to upload at all I dont think.

bigguy:
First edit should be made to the file ModSettings.php in the sources directory:

Find:


--- Quote ---* A check box.  Either one or zero. (boolean)
--- End quote ---

and replace with:


--- Quote ---* A textarea. For multilineal textual values.
   ie. array('textarea', 'nameInModSettingsAndSQL', array('OptionalHeightInRows',
         'OptionalWidthInCols'), &$txt['OptionalDescriptionOfTheOption'],
         'OptionalReferenceToHelpAdmin'),

   * A check box.  Either one or zero. (boolean)
--- End quote ---

In the same file find:


--- Quote ---<td class="windowbg2"><label for="' . $config_var[1] . '">' . (isset($config_var[3]) ? $config_var[3] : $txt[$config_id]) . '</label></td>
                     <td class="windowbg2" width="50%">';
--- End quote ---

And replace with:


--- Quote ---                     <![CDATA[<td class="windowbg2" valign="top"><label for="' . $config_var[1] . '">' . (isset($config_var[3]) ? $config_var[3] : $txt[$config_id]) . '</label></td>
                     <td class="windowbg2" valign="top" width="50%">';
--- End quote ---

In same file find:


--- Quote ---// If it's a password...
--- End quote ---

Add before:


--- Quote ---      <![CDATA[// If it's a textarea.
      elseif ($config_type == 'textarea')
         $context['raw_data'] .= '<textarea id="' . $config_id . '" name="' . $config_id . '"' . (isset($config_var[2][0]) ? ' rows="' . $config_var[2][0] . '"' : '') . (isset($config_var[2][1]) ? ' cols="' . $config_var[2][1] . '"' : '') . ' style="font-family: monospace;">' . htmlspecialchars($modSettings[$config_id]) . '</textarea>';
--- End quote ---

In same file find:


--- Quote ---// Text and passwords!
--- End quote ---

Before that add:


--- Quote ---// Textarea.
      elseif ($var[0] == 'textarea')
         $setArray[$var[1]] = $_POST[$var[1]];
--- End quote ---

In same file find:


--- Quote ---   );

   return $config_vars;
--- End quote ---

After that add:


--- Quote ---      array('heading', &$txt['js_ads_title']),
         // Display the ads??
         array('check', 'js_text_displayads_index'),
         array('check', 'js_text_displayads_botindex'),
         array('check', 'js_text_displayads_board_index'),
         array('check', 'js_text_displayads_display'),
         array('check', 'js_text_displayads_message_index'),
         array('check', 'js_text_displayads_firstpost'),
         array('textarea', 'js_text_content',array('10','50'), &$txt['js_text_disc'],'js_text_help'),
      ]]
--- End quote ---

These are edits for 1 file in  ad_mod_1-0-7_v1-0-2b for smf 1.0.7

Navigation

[0] Message Index

[#] Next page

Go to full version