Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> How To's
Author Message
jondvb
Regular
Regular


Joined: Oct 25, 2003
Posts: 67

PostPosted: Sun Jan 30, 2005 1:15 pm Reply with quote

First, I am trying to greate a new topic, and I only have one choice for an image. I copied several images to the /themes/V-BlueBaby/images/topics/ folder and still can only select the /phpnuke.gif. Any ideas?

Second, I am receiving the following error on my contactus module:

Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in ....../josephwarrenlodge.com/includes/sql_layer.php on line 286

I'm using Nukestyles Contactus Plus and line 286 reads:

281 {
282 global $dbtype;
283 switch ($dbtype) {
284
285 case "MySQL":
286 $row = mysql_fetch_row($res);
287 return $row;
288 break;;
289
290 case "mSQL":
291 $row = msql_fetch_row($res);
292 return $row;
293 break;;

Any help would be GREATLY appreciated.


Last edited by jondvb on Mon Jan 31, 2005 8:43 am; edited 1 time in total 
View user's profile Send private message
kguske
Site Admin


Joined: Jun 04, 2004
Posts: 6383

PostPosted: Mon Jan 31, 2005 8:26 am Reply with quote

Try moving your topics images from /themes/V-BlueBaby/images/topics/ to /images/topics/.

Not sure what the ContactPlus error is, but it sounds like a configuration issue - it's can't connect or read the database.

Finally, I would recommend that you remove the full path from your post (in the error message). People can use that for inappropriate purposes.

_________________
I google, therefore I exist...
Only registered users can see links on this board! Get registered or login!
 
View user's profile Send private message
jondvb
PostPosted: Mon Jan 31, 2005 8:44 am Reply with quote

kguske....thanks for the advice.

I just hacked the DB in myphpadmin to point to the corresponding images.

Another question....I am not able to find the location of the block images. How do I change the image at the top of each block?
 
kguske
PostPosted: Mon Jan 31, 2005 9:09 am Reply with quote

That's specific to the theme, and it's probably in a directory under the theme directory. Check the /themes/V-BlueBaby/theme.php - the images are probably in /themes/V-BlueBaby/images
 
jondvb
PostPosted: Mon Jan 31, 2005 9:28 am Reply with quote

Hi hguske,

I am searching theme.php and don't think that is where the block images are controlled. I do see the block images in the /themes/V-BlueBaby/images folder, but do not know which .php is pulling them? The generic blocks all have the images at top, but any new blocks use generic fint. I want to create my own block images and use them for the new blocks I add to the site.

Thanks.
 
kguske
PostPosted: Mon Jan 31, 2005 10:15 am Reply with quote

In theme.php, search for the specific image name (e.g. box_r1_c1.gif). You'll see it in several place (e.g. function OpenTable, function themeindex, function themesidebox). If you just want to change the blocks' appearance, just change function themesidebox.
 
jondvb
PostPosted: Mon Jan 31, 2005 10:32 am Reply with quote

Hi kguske,

These images, as you mention, just control the look and feel of the blocks. There is a place where the titles of the blocks are held. I need to find that. I'm not worried about the look and feel from a theme standpoint, I need to change the heading in the actual block. I open the .php file of each block and don't see anything pointing to the image at the top of the block.
 
kguske
PostPosted: Mon Jan 31, 2005 10:37 am Reply with quote

The block title isn't an image, it's text defined in the Blocks administration (most PHP-Nuke themes work this way, though there are a few that use flash or other approaches, but it's still driven by the Title in the Blocks administration). Just change the block "Title" to be whatever you want.
 
jondvb
PostPosted: Mon Jan 31, 2005 10:48 am Reply with quote

Hi Kguske,

Can you please take a look at the site?
Only registered users can see links on this board! Get registered or login!

Look at the Main Menu block. Main Menu is an image, located in the themes/images/blocks folder. I can not find a single .php file that calls this image file.
 
kguske
PostPosted: Mon Jan 31, 2005 11:20 am Reply with quote

I see. Let me check that theme later this afternoon and I'll tell you what I find.
 
kguske
PostPosted: Mon Jan 31, 2005 2:52 pm Reply with quote

There is some code in the theme.php, function themesidebox that controls the display of the graphical header:

Code:


                        $img_name=explode(" ",$title);
                        $img_nametwo=$img_name[0];
                        if(file_exists("themes/V-BlueBaby/images/blocks/$img_nametwo.gif")) {
                                echo "<IMG SRC=\"themes/V-BlueBaby/images/blocks/$img_nametwo.gif\"><br /><br />";
                        } else {
                                echo "$title<br />\n";
                        }


This code looks for the existence of the graphic with the same name as the block, and displays the graphic instead of the title if the graphic exists. You could modify this, replace the graphic with your own, or remove/rename the graphic to display a text title instead.
 
jondvb
PostPosted: Mon Jan 31, 2005 2:57 pm Reply with quote

Amazing.

I'll give this a shot and let you know how it worked.

Thanks for finding this!
 
jondvb
PostPosted: Mon Jan 31, 2005 3:03 pm Reply with quote

LOL that worked.

THANK YOU SO MUCH!
 
kguske
PostPosted: Mon Jan 31, 2005 3:09 pm Reply with quote

No problem. I haven't seen that approach in any other theme - it's definitely a bit unusual....
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> How To's

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©