Author |
Message |
andyb2
Regular
Joined: Aug 26, 2012
Posts: 60
|
Posted:
Tue Aug 28, 2012 1:35 pm |
|
Hi ladies & gents;
I'm working on a new theme- if anybody wants it when I've done, your welcome.
It's based on Ricktido (you probably guessed! )
Basically- plan so far- remove the logo at the top, reduce size of the RSS, Twitter & Facebook logos, and move the search box.
The issue I have -for now- is the search box.... I've reduced it's size, but....
You can see it's "low down"- wanted it to follow on from nukenav....
Code in my theme.php:
Code:echo '<div class="subheader"><div class="subheaderl"><img class="topleft" src="themes/'.$ThemeSel.'/images/topleft.png" alt="" /><div class="subheaderlh1"></div><br /><br /><br /><div class="subheaderlh2"></div>'.$nukeNAV.''.$searchboxcode.'</div><div class="subheaderr text-center"><img class="topright" src="themes/'.$ThemeSel.'/images/topright.png"</div></div></div>';
|
I've done a quick validation, and received errors:
Code:Validation Output: 39 Errors
Warning Line 84, Column 597: unclosed start-tag requires SHORTTAG YES
…rc="themes/AFnet2/images/topright.png"</div></div></div><div id="mainbodycolor…
✉
The construct <foo<bar> is valid in HTML (it is an example of the rather obscure “Shorttags” feature) but its use is not recommended. In most cases, this is a typo that you will want to fix. If you really want to use shorttags, be aware that they are not well implemented by browsers.
Error Line 84, Column 597: required attribute "alt" not specified
…rc="themes/AFnet2/images/topright.png"</div></div></div><div id="mainbodycolor…
✉
The attribute given above is required for an element that you've used, but you have omitted it. For instance, in most HTML and XHTML document types the "type" attribute is required on the "script" element and the "alt" attribute is required for the "img" element.
Typical values for type are type="text/css" for <style> and type="text/javascript" for <script>.
Error Line 84, Column 602: end tag for "img" omitted, but OMITTAG NO was specified
…hemes/AFnet2/images/topright.png"</div></div></div><div id="mainbodycolor"><!-…
✉
You may have neglected to close an element, or perhaps you meant to "self-close" an element, that is, ending it with "/>" instead of ">".
Info Line 84, Column 536: start tag was here
…v><div class="subheaderr text-center"><img class="topright" src="themes/AFnet2…
|
There were more, most of which I'll work through over the next few days or so.....
Comments/ suggestions welcome- particularly with the search box.
I've got it so that I can put a log over the random background image, but my logo is either too big, or not done to look "professional" enough...
Plan is to maybe put the twitter/ RSS/ Facebook under each other on the left hand side above nukenav |
Last edited by andyb2 on Sat Sep 01, 2012 7:43 am; edited 1 time in total |
|
|
|
neralex
Site Admin
Joined: Aug 22, 2007
Posts: 1775
|
Posted:
Tue Aug 28, 2012 2:36 pm |
|
The searchbox is an floated block element and the nukeNAV, too. If you want the searchbox besides the nukeNAV, then you must float both containers and clear it all after the searchbox. I hope you have seen, the searchbox has an static background graphic with a another background color as your content area. Do you realy want the searchbox besides the nav? I think your validation errors comes from a wrong placing of your used elements. |
|
|
|
|
nuken
RavenNuke(tm) Development Team
Joined: Mar 11, 2007
Posts: 2024
Location: North Carolina
|
Posted:
Tue Aug 28, 2012 4:53 pm |
|
That search box uses a lot of css to make it work and that css depends on the size and position of the search box to work. IE 7 also has a bug that has to be addressed with separate css classes just for it. It would take a lot of trial and error to relocate it. |
_________________ Tricked Out News |
|
|
|
andyb2
|
Posted:
Thu Aug 30, 2012 6:46 am |
|
is there an alternative searchbox/ option I can use at the end of nukenav? |
|
|
|
|
andyb2
|
Posted:
Thu Aug 30, 2012 8:38 am |
|
and also (while I'm asking)- if I have no right blocks, how do I make it so the theme is fully utilised? My news parts aren't going to the far right- they stop as if there is another column. (Right blocks are visible in admin control panel, BUT they are all disabled on the site)
(I've removed the code for the search box)) |
|
|
|
|
nuken
|
Posted:
Thu Aug 30, 2012 10:28 am |
|
You can use any search box you want to. There are many examples on google and some on other themes. You should be able to make the news full width by editing the
Code:
if (!defined('INDEX_FILE')) define('INDEX_FILE', true); // Set to FALSE to hide right blocks
if (defined('INDEX_FILE') AND INDEX_FILE === true) {
// auto set right blocks for pre patch 3.1 compatibility
$index = 1;
}
|
from the news index.php like you would any module you want to not include the right side blocks. |
|
|
|
|
andyb2
|
Posted:
Fri Aug 31, 2012 2:11 am |
|
ha- thanks for the heads up on the code- I was looking at changing it in theme.php .. but not good if anybody else would like to use the theme.... |
|
|
|
|
andyb2
|
Posted:
Fri Aug 31, 2012 6:54 am |
|
next update (and more questions), if you guys could be so kind?
In the image below, you can see the news bit has a blueish background; I've tried modifying various aspects (to make it a light grey) and nothing seems to make a difference? If somebody could please advise?
And in the image below, you can see when you click through to the news article, the background is completely gone. I managed to change the header background, but ideally I want it to be the same as the homepage- light grey graded...
Help appreciated; I feel like I am finally getting somewhere...
A couple more things; I've dropped a clanger somewhere with the code- the "disqus" part doesn't show until the very bottom/ end of the left hand blocks- when I select forums as well, that does the same thing. (Like I've missed a closing tag somewhere?)
I did try to move the complete forums theme part across from my old theme and place it within the theme section, but that didn't work.... |
Last edited by andyb2 on Sat Sep 01, 2012 7:43 am; edited 1 time in total |
|
|
|
andyb2
|
Posted:
Fri Aug 31, 2012 9:39 am |
|
using firefox and chrome and inspection plug ins to decipher the code.... found the image for the news background.. (I feel a chump)- one more ticked off the list.... still the issue with forums, etc. I keep walking away from the PC, doing something else, then coming back to it.... |
|
|
|
|
andyb2
|
Posted:
Fri Aug 31, 2012 1:33 pm |
|
ok; more ticked off the list; forums etc. are now showing in the correct place, BUT the forums look like they are picking up an old stylesheet (looking for /afnet_grey, new one is afnet2)
The code from inspecting the elements etc. (in Chrome and Firefox)
Code:link rel="stylesheet" href="themes/afnet_grey/style/style.css" type="text/css"
|
Obviously it's as if something is "hard coded" somewhere- I've searched in the database, and tried looking into various files. Can I find it?
Probably going to be something really, REALLY simple.
All I did was copy my old /theme/forum folder complete from the old theme into the new theme....
None of the images/ links/ etc. show correctly.
I can upload an image later, if it helps? (PC running VERY slow) |
|
|
|
|
andyb2
|
Posted:
Sat Sep 01, 2012 7:54 am |
|
ok;
learning curve, I guess...
managed to find all the hard coded bits when I finally managed to get dreamweaver up and running to search for the offending code....
I've been experimenting this morning- it doesn't appear to be picking up the styles for the forum? It will pick images up when I force a hard refresh- the image below shows when I've moved the themes/forum folder from CT black -I expected it to pick up the colours from it's css, but doesn't?
Are these coded within the main site css?
I know I'm asking a lot of questions, and learning at the same time. Hopefully my experiences with this may help others... |
|
|
|
|
neralex
|
Posted:
Sat Sep 01, 2012 5:22 pm |
|
In the most themes you have an extra file for the forums styles in your theme style-folder. Its called Forums.css. But some themes have the forums styles in the style.css. Here you must campare. Its different from theme to theme. |
|
|
|
|
andyb2
|
Posted:
Sun Sep 02, 2012 1:35 am |
|
I know; this is specifically to do with Ricktido- a "common" distributed theme with RN?
It picks up the images etc., but that be because they are named the same in all themes/ same location.
The only thing I can see with the forums in themes is this: Code:/* For Forum Attachment Mod */
td.attachrow { font: normal 11px Verdana, Arial, Helvetica, sans-serif; }
td.attachheader { font: normal 11px Verdana, Arial, Helvetica, sans-serif; }
table.attachtable { font: normal 12px Verdana, Arial, Helvetica, sans-serif; border-collapse : collapse; }
th.thLeft {min-width:150px; padding:4px;}
td.row1 {padding:4px;}
td.row2 {padding:4px;}
|
I'm kind of struggling with this one- and I think it's the last thing to get sorted..... |
|
|
|
|
andyb2
|
Posted:
Sun Sep 02, 2012 7:02 am |
|
I've cheated..... I've added the forum.css to the main css at the bottom then tweaked.....
Is this a BAD thing? |
|
|
|
|
nuken
|
Posted:
Sun Sep 02, 2012 8:36 am |
|
I don't know about the CT-Black theme, but a lot of Clan Themes forum themes have the css included in the style.css instead of using a separate forum.css file. You may need to look on the style.css to get your styling.... |
|
|
|
|
andyb2
|
Posted:
Sun Sep 02, 2012 10:24 am |
|
done that. checked as many links/ items as possible, tweaking graphics and stuff- am about to upload to the site and make it live- see how much I've broken then... lol. |
|
|
|
|
andyb2
|
Posted:
Sun Sep 02, 2012 12:26 pm |
|
site live, if anyone wants to take a look.... if anyone wants the theme, drop me a PM- you'll need to make changes (as per usual)- [ Only registered users can see links on this board! Get registered or login! ]
Thanks for everybody's input.... |
|
|
|
|
andyb2
|
Posted:
Mon Sep 03, 2012 6:55 am |
|
I have found an issue, and I'm not sure how I'll get around this.
Users can "link" photos/ images into their posts. The problem is if the image is 800 wide, the right hand side of the forums disappear, and you can't see all the text....
Any ideas?
|
|
|
|
|
neralex
|
Posted:
Mon Sep 03, 2012 7:27 am |
|
You can use a max-width value for the images in the postings. Open your forum css and add this one. Change the value so that it fits and no longer overlaps.
Code:.postbody img {
max-width: 750px;
}
|
|
|
|
|
|
andyb2
|
Posted:
Mon Sep 03, 2012 8:39 am |
|
you, sir, are a gentleman and a scholar. Many thanks, worked a treat |
|
|
|
|
andyb2
|
Posted:
Mon Sep 03, 2012 11:05 am |
|
neralex could you possibly help with this issue also, please?
When looking at admin- news goes off to the right similar to previous issue...
If it's best to disable the left blocks, not a problem if you could advise? I tried it in the same way the file is edited for if you have the forums, but it didn't appear to work....
|
|
|
|
|
neralex
|
Posted:
Mon Sep 03, 2012 12:04 pm |
|
andyb2, i have an idea for your problem. I'll write a charcounter for length of the news and topic title. Thus the length of the title is shortened. Give me some minutes and i will update my mod.
|
Last edited by neralex on Mon Sep 03, 2012 3:08 pm; edited 1 time in total |
|
|
|
neralex
|
Posted:
Mon Sep 03, 2012 12:52 pm |
|
Ok i have updated my mod on github! Download the package again and overwrite the admin.php and index.php in the admin folder of the News module.
[ Only registered users can see links on this board! Get registered or login! ]
html - admin.php
html - modules - News - admin - index.php
open the both files and search:
set the variable to 1.
After this, the topictext is shortend after 20 chars and the title is shortend after 40 chars!
After this, please copy the NewsAdmin.css from the style folder of the theme RickTido into the style folder of your your theme. In this css file you can set specific styles only for the news-mod and you can set a font-size in the news archive, too.
html - themes - RickTido - style - NewsAdmin.css
move into:
html - themes - AFnet2 - style - NewsAdmin.css
open this file and search:
Code:.archivelist {border-top:1px solid; border-bottom:1px solid;}
|
add to this class the font-size value. It could looks like this or smaller as 80%:
Code:.archivelist {border-top:1px solid; border-bottom:1px solid; font-size:80% !important;}
|
I will try to write some lines for RickTido to hide the left blocks in the admin section. |
Last edited by neralex on Mon Sep 03, 2012 3:49 pm; edited 1 time in total |
|
|
|
neralex
|
Posted:
Mon Sep 03, 2012 1:18 pm |
|
Ok i have a solution for admin section in full width, too!
open your theme.php and search:
Code:function themeheader() {
global $banners, $sitename, $slogan, $prefix, $nukeNAV, $name, $db, $ThemeSel, $hide_blocks_left;
|
add at the end of the line with the globals the variable $module_name and remove the variables $hide_blocks_left and $name
Code:function themeheader() {
global $banners, $sitename, $slogan, $prefix, $nukeNAV, $db, $ThemeSel, $module_name;
|
find in the same function:
Code:if (!in_array($name, $hide_blocks_left)) {
|
change it to:
Code:if (($module_name != 'Forums') && (!defined('ADMIN_FILE'))) {
|
now search:
Code:function themefooter() {
global $index, $banners, $foot1, $foot2, $foot3, $foot4, $name, $hide_blocks_left;
|
add at the end of the line with the globals the variable $module_name and remove the variables $hide_blocks_left and $name
Code:function themefooter() {
global $index, $banners, $foot1, $foot2, $foot3, $foot4, $module_name;
|
find in the same function:
Code:if (defined('INDEX_FILE')and !in_array($name, $hide_blocks_left)) {
|
change it to:
Code:if (defined('INDEX_FILE') && ($module_name != 'Forums') && (!defined('ADMIN_FILE'))) {
|
After the changes you have now the admin section in full width with hided left blocks. The variable $hide_blocks_left is now not more in use. If you want hide the left blocks from other modules, then you must add this in the lines with !defined('ADMIN_FILE'). For example to hide left blocks in the Your Account module you can try this:
find after saving all changes:
Code:if (($module_name != 'Forums') && (!defined('ADMIN_FILE'))) {
|
change it to:
Code:if (($module_name != 'Forums') && ($module_name != 'Your_Account') && (!defined('ADMIN_FILE'))) {
|
find:
Code:if (defined('INDEX_FILE') && ($module_name != 'Forums') && (!defined('ADMIN_FILE'))) {
|
change it to:
Code:if (defined('INDEX_FILE') && ($module_name != 'Forums') && ($module_name != 'Your_Account') && (!defined('ADMIN_FILE'))) {
|
Here you can compare the complete modded theme.php from the RickTido theme with hided blocks in the admin section and in the Your Account module:
[ Only registered users can see links on this board! Get registered or login! ]
|
|
|
|
|
andyb2
|
Posted:
Mon Sep 03, 2012 3:19 pm |
|
thanks. I will look into doing the first modification hopefully tomorrow.
thanks.for a prompt and thorough response! |
|
|
|
|
|