<? DEW-CODE.COM  

Downloads

Assorted scripts  (1)
DewNewPHPLinks  (9)





Lost Password?
No account yet? Register

Dew-Code Newsfeed

Resources


 USdigitalcable.com

Dew-Code
Welcome, Guest
Please Login or Register.    Lost Password?
Better support for customization (1 viewing) (1) Guest
Go to bottom Post Reply Favoured: 0
TOPIC: Better support for customization
#1120
hpstudios (User)
Fresh Boarder
Posts: 6
graphgraph
User Offline Click here to see the profile of this user
Gender: Female High Frequency Guide Location: NYC
Better support for customization 2 Years, 8 Months ago Karma: 0  
Hi, everyone.

I just discovered this script recently and think it's absolutely perfect functionality wise.

But I just can't get past the difficulty in customizing it. I've spent the past day and a half staring at all this code trying to deal with it but I can't. It seems as if the design of the pages are hard-wired into the php coding itself so that only someone with programming knowledge can customize it. Isn't there any way you can make it so the html/ css portion of the pages is separated from the php coding by way of "includes"? So that all one would have to do is just edit the html and change the layout to your liking without having to worry about the php?
 
Report to moderator   Logged Logged  
 
High Frequency Guide.net- a growing directory of free shows, movies, and other online entertainment!
  The administrator has disabled public write access.
#1121
Dewed (Admin)
Admin
Posts: 606
graph
User Online Now Click here to see the profile of this user
Dew-Code.com
Re:Better support for customization 2 Years, 8 Months ago Karma: 9  
Short answer.. probably. And I agree, it's not as straight forward as it could be.

I didn't write the original version of this script. In fact the script I maintain is a branch of a branch.. of a branch I think, originally written in 1999, for the then cutting edge PHP3/MySQL3 platform. Overall, the structure hasn't changed much.

You'll find plain old stylesheets in the /themes directory, and files within your themes directory, like header.php, footer.php really are just HTML, that is defined as a PHP variable.

Code:

<img src="pathtoimage.gif" height="100" width="100">
becomes
Code:

$html ="<img src=\"pathtoimage.gif\" height=\"100\" width="100">";
Then, by using dot equals, you can append more HTML to that
Code:

$html .="<p><i>What a pretty picture</i></p>";
Later on, the $html variable is printed out, flushed from your servers memory and repopulated, to create the pages you see. I suspect that was done because the original version made heavy use of sessions, and controlling output to the browser is crucial in making sessions work. Many people are able to get a look that works with their site by limiting edits to the header.php file and the stylesheet. Depending on your version you may have a theme that is a better starting point than the default. You can copy that directory, like "original" to a new theme directory, "mytheme" for example. Use the admin config page to select that theme, and edit the stylesheet as needed. This forum exists to help you do what you want with it. And while I can be hired to do the work for you, I'm happy to answer any questions I am able to through the forum.
 
Report to moderator   Logged Logged  
 
Nothing to it but to Dew it !
Dew-Code.com
  The administrator has disabled public write access.
#1122
hpstudios (User)
Fresh Boarder
Posts: 6
graphgraph
User Offline Click here to see the profile of this user
Gender: Female High Frequency Guide Location: NYC
Re:Better support for customization 2 Years, 8 Months ago Karma: 0  
Hi... Thank you for your quick response.

I know about changing the stylesheets and all (thanks ) I suppose what I'm looking to do is to restructure/ change the layout with new tables so that I can add my own content or perhaps even redo the layout using divs. I see the separate files (header.php, footer.php, etc) that control separate sections of the layout. But I'm not seeing how to restructure the layout itself like the way this site did: http://www.totallyfuzzy.net/directory/.

I don't really need a step by step method, just some basic concepts that explain how your guest made those "alt_theme" layouts and shifted things around.
 
Report to moderator   Logged Logged  
 
Last Edit: 2009/09/10 08:47 By hpstudios.
 
High Frequency Guide.net- a growing directory of free shows, movies, and other online entertainment!
  The administrator has disabled public write access.
#1123
Dewed (Admin)
Admin
Posts: 606
graph
User Online Now Click here to see the profile of this user
Dew-Code.com
Re:Better support for customization 2 Years, 8 Months ago Karma: 9  
The owner of the site you mention actually hired me. After my initial work on the template's layout he wound up customizing it further adding some pretty cool stuff.


but in short..

Started by adding an outermost div to the top of /theme/X/header.php, and an inner div
to contain the scripts normal output, leaving room for the additional sidebars...

<div id="outer-wrapper">
<div id="header"> LOGO, etc

</div>

and at the bottom of header.php

<div style="clear: both;"></div>
<div id="main-wrapper">

Then, editing footer.php, adding this near the top ...

<div style="clear: both;"></div>
</div> <!-- eof div main-wrapper -->
<div id="sidebar">
<?
include("sidebar.inc";
?>

</div><!-- eof div class=sidebar> -->



and of course at the bottom of the footer.php, closing the outmost div

</div> <!-- eof div id=outer-wrapper -->


Then added something like this to the stylesheet . . . .


#outer-wrapper {width:932px;padding:0px 0px; text-align:left; float:left;}

#main-wrapper {width:510px;}

#sidebar {width:200px;margin-left:1px;margin-right:1px;}

Granted, that is an overly simplified version of what was done, because
development on that site was..., let's say, very involved.

Alot of custom work was done in the admin panel too, some of which found its way
into the current version.
 
Report to moderator   Logged Logged  
 
Nothing to it but to Dew it !
Dew-Code.com
  The administrator has disabled public write access.
#1124
hpstudios (User)
Fresh Boarder
Posts: 6
graphgraph
User Offline Click here to see the profile of this user
Gender: Female High Frequency Guide Location: NYC
Re:Better support for customization 2 Years, 8 Months ago Karma: 0  
QUOTE:
Started by adding an outermost div to the top of /theme/X/header.php, and an inner div
to contain the scripts normal output, leaving room for the additional sidebars...


Okay, just one teensy question... When you add these divs, do you add them still using "$html .="?

For example:

Code:

$html .="<div style="/header/">Content content content</div> ";
Thank you very much for your response.; it helped a lot. I will see what I can do with my site. Hopefully, if I get a handle on it, I'll be able to throw some new schemes out there, since I read somewhere else on this forum that very few people have done that, which is a shame, because I think your script is excellent and I would love to help contribute in some way!
 
Report to moderator   Logged Logged  
 
Last Edit: 2009/09/10 19:12 By hpstudios.
 
High Frequency Guide.net- a growing directory of free shows, movies, and other online entertainment!
  The administrator has disabled public write access.
Go to top Post Reply
get the latest posts directly to your desktop
Outsource your projects to thousands of programmers at
ScriptLance.com
Newsflash
Interested in
advertising?

This space for rent!

Sign up for PayPal and start accepting credit card payments instantly.
Copyright Dew-Code 2008