<?xml version="1.0" encoding="iso-8859-1"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>CrankBerry Blog &#187; Web Development</title>
	<atom:link href="http://www.crankberryblog.com/category/web-development/feed" rel="self" type="application/rss+xml" />
	<link>http://www.crankberryblog.com</link>
	<description>Sharing ideas on web design, development and the internet economy</description>
	<lastBuildDate>Thu, 22 Apr 2010 21:46:50 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Image optimization for web design and development</title>
		<link>http://www.crankberryblog.com/2010/image-optimization-for-web-design-and-development</link>
		<comments>http://www.crankberryblog.com/2010/image-optimization-for-web-design-and-development#comments</comments>
		<pubDate>Tue, 16 Feb 2010 19:40:03 +0000</pubDate>
		<dc:creator>Jerry Low</dc:creator>
				<category><![CDATA[Web Design]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[Bandwidth]]></category>
		<category><![CDATA[Image Optimization]]></category>
		<category><![CDATA[Load Size Reduction]]></category>

		<guid isPermaLink="false">http://www.crankberryblog.com/?p=311</guid>
		<description><![CDATA[Between a good design a good development there's a path in between that we all must cross which is converting your design into a functional website. An aspect to really consider now a days is loading time of the website. There are many variables that contribute to a site's load time which includes server and client aspects and everything in between. Today we will focus specifically on loading the images on the site and how you can optimize them for best performance.

<img src="http://www.crankberryblog.com/images/image-optimization.jpg" alt="Image Optimization" />]]></description>
			<content:encoded><![CDATA[<p>Between a good design a good development there&#039;s a path in between that we all must cross which is converting your design into a functional website. An aspect to really consider now a days is loading time of the website. There are many variables that contribute to a site&#039;s load time which includes server and client aspects and everything in between. Today we will focus specifically on loading the images on the site and how you can optimize them for best performance.</p>
<p><img src="http://www.crankberryblog.com/images/image-optimization.jpg" alt="Image Optimization" /></p>
<h2>The Design Aspect</h2>
<p>I always tell myself and people who design for me to not worry about the design. I can always code it and optimize it for the web. Although this maybe true I don&#039;t always design with that mentality. I usually keep the user of the website in mind. I never try to overkill the design just because I want to, but this is coming from a developer&#039;s thoughts. </p>
<p>Regardless, if you are one who is highly concerned about the graphical load time then design with that in mind. You can cut down on size by using design elements that you know can be replaced by CSS 2.0 standard coding. So we&#039;re talking about solid boxes, solid lines and etc. We&#039;ll go further into that in the CSS section. Using heavy graphics and lots of blending will add up in size. Something like that looks like Crankberry will cost you around 700 KB in image size with the whole page loading around 1 MB. I cater to designers and developers so fairly average for today&#039;s standard. </p>
<p>With that, keep those thoughts in mind when designing because if you design first then noticed that the site bogs down then you&#039;ll be going back many steps just to make revisions to that.</p>
<h2>Keeping the Balance</h2>
<p>As mentioned in the beginning of the article that there are many things that dampens the load time of your site. The way your content is drawn onto the pages is also a factor that may affect the speed. Static contents won&#039;t pull you down much unless you&#039;re uploading novels and encylclopedias on one page but then you have other problems to worry about don&#039;t you. Anyways, if your website pulls a lot of content from your database per page with lots of joins and queries then your content is also factored in. In these scenarios I usually recommend keeping a balance to mitigate high load times. So if you have a lot of heavy database interaction I would recommend keeping the design and graphics to a lower end. On the contrary if you don&#039;t have a lot of database interaction I may not recommend super heavy design just means that you&#039;re more flexible. Refer back to the last section as to how to optimize your design.</p>
<h2>JPEG vs GIF vs PNG</h2>
<p>Now that you&#039;re done your designing its time to slice the images up and start structuring your HTML and CSS. When saving your image files you have so many options as to which file format to save it as. You&#039;ve got JPEG, GIF, PNG, Bitmap, TIFF and the list goes on and on. Just to shorten your list down, I would stick to three primary formats: JPEG, GIF, and PNG. All the other formats for development wise can be forgotten. Now some people like to consistenty use one format throughout their whole website but I like to switch it up. I prefer to use JPEG, GIF and sometimes PNG. I&#039;ll go into further details about which I use and when I use it in a bit. First of all you should understand the difference between all these formats. There has been many articles written over this topic so it would be super redundant to do it again. I&#039;ll spare you the theatrics and give you the highlights.</p>
<p><strong>JPEG</strong></p>
<ul>
<li>Lossly compression</li>
<li>Compresses colors and grayscale</li>
<li>Used for complex images</li>
</ul>
<p><strong>GIF</strong></p>
<ul>
<li>Lossless compression</li>
<li>256 Colors</li>
<li>Good for line and simple drawings</li>
<li>Supports animation</li>
<li>Supports transparency</li>
</ul>
<p><strong>PNG</strong></p>
<ul>
<li>Lossless compression</li>
<li>Patent-free GIF</li>
<li>Supports transparency with opacity setting</li>
</ul>
<h2>Which to Use</h2>
<p>After reading the above part you maybe wondering how this infomation reflects on your files format and which one you should use. Here&#039;s how you look at it. Lean towards GIF and JPEG and if necessary then use PNG.</p>
<p>Lets start with why minimal use of PNG. PNG is a nice format format in replacement of GIF. When saving the same simple GIF file in PNG you can end up with a smaller file size as PNG does a better job in compression. The reason I still don&#039;t use PNG much is because some of the older, non-main stream and mobile browsers don&#039;t have a good support for PNGs. There are ways to go abouts for this but to accomodate for all browsers would be very timely. As I always focus to present a cross-browser compatible website I stay away from this format.</p>
<p>Now then, we&#039;re left with the JPEG and the GIF. It is very simple when it comes down to these two contenders. If the image you&#039;re saving has lots of colors and blending then go for the JPEG if it has simple lines and text and solid color go for the GIF. Your sizes will optimized this way.</p>
<p><img src="http://www.crankberryblog.com/images/image-optimization-example-jpeg.jpg" alt="Image Optimization with JPEG" /></p>
<p><img src="http://www.crankberryblog.com/images/image-optimization-example-gif.jpg" alt="Image Optimization with GIF" /></p>
<p>Here I took a screenshot of my currently portfolio (top design) which should most of the images should be saved in JPEG due to the complexity of the images and colors. The second screenshot is of FusedEffects which should mostly be saved in GIF due to the simple lines and large blobs of solid colors.</p>
<h2>Good Practice</h2>
<p>Obviously if you&#039;ve got all that down you can quickly decide which format to use and how much compression you may want to do. If you&#039;re lazy like myself and you have Photoshop the best thing to do is to use their [Save as for Web] setting. The window it popups up with will give you the image size before you even save it.</p>
<p><img src="http://www.crankberryblog.com/images/image-optimization-good-practice.jpg" alt="Image Optimization Practices" /></p>
<p>This way you can switch between JPEG, GIF, PNG and different settings until you get the quality and size that pleases you.</p>
<h2>The Role of CSS</h2>
<p>Ok ok ok, I mentioned a few times (at least I think) that you can replace certain elements with CSS to eliminate the use of graphics where necessary. I always prefer this method when possible as I tend to think a few lines of code is always smaller than an image size. </p>
<p>Now a days, developers have come up with many creative ways to achieve graphical effects with just a few lines of coding. Such as rounded corners. The trend right now seems to be using rounded corner boxes instead of plain old square. Since CSS 2.0 has no support for rounded corners on div tags people rely on images and positioning. As I have released months ago a script that is <a href="http://www.crankberryblog.com/tool/css-rounded-corners-generator.php">purely css, cross-browser compatible and image-less for rounded corners.</a></p>
<p><img src="http://www.crankberryblog.com/images/css-rounded-corners-with-borders.jpg" /></p>
<p>That&#039;s only one of the many examples in which graphical elements can be replaced by CSS coding. I will be doing a full article on this in the near future so stay tuned for that.</p>
<h3>If You Can&#039;t Replace The Image, Work With It</h3>
<p>In certain cases some pure CSS solutions aren&#039;t as stable yet such as gradient effects you can combine images with CSS to create the effect. So for a full stretch gradient instead of making an image 5000px x 10px just save it as 1px x 10px and use the background: repeat-x; This will save you lots.</p>
<p>In summary, how much can you save by going through so much optimization. This really depends on how heavily you designed your site. As you can tell by my style I like to go heavy with personal designs and light on business designs. Sometimes its not up to you. I work with a designer who over does gradients and shadows everywhere so its up to me to optimized the images. Sometimes I can save up to 500+ KB by doing the right optimization. You maybe thinking that with the advancement of cable internet and the cost of bandwidth going down it doesn&#039;t really matter. Remember its all about the user experience. There are lots of factors involved that contibutes to your site&#039;s load time, try to optimized everything so there&#039;s is minimal lag time. You should also understand that with the advancement of technology more and more people are surfing with their mobile phones or laptops tethered through their mobile phones. Its always a plus for your users when they get the things they&#039;re looking for, faster.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.crankberryblog.com/2010/image-optimization-for-web-design-and-development/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Stats you should know before making a website</title>
		<link>http://www.crankberryblog.com/2009/stats-you-should-know-before-making-a-website</link>
		<comments>http://www.crankberryblog.com/2009/stats-you-should-know-before-making-a-website#comments</comments>
		<pubDate>Wed, 18 Nov 2009 19:15:07 +0000</pubDate>
		<dc:creator>Jerry Low</dc:creator>
				<category><![CDATA[Blogging]]></category>
		<category><![CDATA[Internet Economy]]></category>
		<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">http://www.crankberryblog.com/?p=300</guid>
		<description><![CDATA[Making a website or a blog now-a-days is not easy, given all the tools we have today compared to the early 90's means its not only easier for us but easier for others too. The competitive playground is just so big now a days. This is why your website not only has to be unique but has to cover a few basic things first. Here are some stats and guidelines to help you get started. As well as a look into the business aspect of making a website.]]></description>
			<content:encoded><![CDATA[<p>Making a website or a blog now-a-days is not easy, given all the tools we have today compared to the early 90&#039;s means its not only easier for us but easier for others too. The competitive playground is just so big now a days. This is why your website not only has to be unique but has to cover a few basic things first. Here are some stats and guidelines to help you get started. As well as a look into the business aspect of making a website.</p>
<h3>Website Name</h3>
<p>When I was a younger starting a website or a project was easy. Just come up with a name that I liked and then just purchase the relevant domain after. Today, its not the case, we name websites and projects based on domain availabilities and possibly price. Just to give you a scope there are 112,961,783 active domains currently, with 83,320,335 of that being a .com domain (1). Although the combination of words for domain is near endless, it&#039;ll be harder and harder to get the name you want.</p>
<p>It will eventually boils down to resorting to a longer domain name, unique play on words or purchasing pre-owned domains at a premium pricing.</p>
<h3>The Design</h3>
<p>Once you&#039;re ready to start designing your website you&#039;ll have to put into perspective how big or small to design it. Just because you have a 14&#034; or a 36&#034; monitor doesn&#039;t mean that everybody does as well. As of January 2009 57% of detectable users are displaying at higher than 1024&#215;768 px. There are 36% users at 1024&#215;768 and 4% less than that (2).</p>
<p>Understanding your target users is very important. If you cater to teenagers than a higher percentage of your user will end up in the 1024&#215;768+ category. If you cater to an older or well aged audience then you&#039;ll probably have more users in the 1024&#215;768 or below category. If you cater to graphic artists and designers then you most like have a much higher resolution to work with. </p>
<p>I tend to use a 1400&#215;1100 canvas for my design and keep content within a 1200&#215;1100 or 1000&#215;1100 box, the remaining area is for the design of the background. Just like shown below:</p>
<p><img src="http://www.crankberryblog.com/images/stats-for-web-canvas.jpg" alt="Canvas for Web Design" /></p>
<p><strong>Color Wise</strong></p>
<p>You shouldn&#039;t have to worry too much about colors as 95% of users has 24bit or 32 bit hardware supporting up to 16,777,216 colors.</p>
<h3>Developing</h3>
<p>The biggest concern that you should have is how the users view your website once its made into HTML. The most recent stats indicate that 47.5% users online are using Firefox and a collective percentage of 37.5% of users are using IE6, 7 and 8 (3). As you can see a significantly outstanding of majorities use Firefox and IE. </p>
<p>When developing offline I like to test and view my scripts in Firefox and IE7. Once done, I like to view it in IE 6 and tweak things. This step should be the biggest tweaking stage. If everything works in Firefox and IE 6 and 7 the probability (and this is not a probability of 1) of it working on other browsers is pretty good.</p>
<p>When I have time I also like to test the page on different machines and different mobile devices to get a glimpse of how its working out.</p>
<h3>The Money</h3>
<p>With that, lets get to where some of you are truly interested in &#8211; the money. Is there money to be made making websites? Yes, but the competition as said before is high. With 112,961,783 active domains and 50 million blogs (detected in 2006) there arena is just too crowded (4). Ask yourself what you want to do and how that can be done in a unique way.</p>
<p><strong>Who to Target</strong></p>
<p>Defining your target market is a key to a good business and marketing plan. Which demographic do you want to be your key audience? Currently 72% of advertisers find it beneficial to target the 35-44 and 25-34 year old category with them making up 29% and 28% of users online, respectively (5). Don&#039;t let age be the only determining factor for you though, targeting a common interest amongst a group of users could be a break-through factor as well. This may be people who loves sour candies, office interiors or just residing in the same local area. A combination of criteria may make it more unique for you as well such as people aged 16-24 who likes sour candies or people of aged 35-44 living in the same city.</p>
<p>By detailing and being more specific about your target market may give you a bit of a competitive edge but understand that by adding more criteria to the list you are shrinking the size of your target. Ask yourself, if you have a smaller market to serve can you still sustain? If you sell a product that&#039;s $1 and you target 25-34 y/o male residents a suburban area you may not have enough potential clients to survive. Do some math and see where you want to end up, that should give you a scope of how many people you may potential need to target.</p>
<p><strong>Making Money Through Advertisement</strong></p>
<p>Some of you webmasters are planning to make money through advertisement, this maybe through a 3rd party company such as Google Adsense or Adbrite or just handle advertisement internally. You should know that there&#039;s still plenty of advertising dollars floating around the internet for you to make, it all just depends if you know how to get it. </p>
<p>Focusing on North American market here, despite the depression and economic downturn organizations are keeping a budget ready for internet advertisement. There&#039;s many factors why this is, which is slightly irrelevant here but keep in mind that this dollar amount will continue to grow proportionate to the growth of how many and how often people access the internet on a daily base.</p>
<p>The outlook for 2009 was an 8.9% growth in overall internet advertisement spending which equates to $25.7 billion US dollars. This is a good enough motivation for those who wishes to make a career out of websites and advertisements (6).</p>
<p>I am just so tire right now so I suppose I&#039;ll edit and update this article as I go.</p>
<p>1. http://www.domaintools.com/internet-statistics/<br />
2. http://www.w3schools.com/browsers/browsers_display.asp<br />
3. http://www.w3schools.com/browsers/browsers_stats.asp<br />
4. http://www.cyberjournalist.net/news/003674.php<br />
5. http://www.eiaa.net/ftp/casestudiesppt/EIAA_Marketers_Internet_Ad_Barometer_2009_PR_Presentation.pdf<br />
6. http://www.emarketer.com/Article.aspx?R=1006813</p>
]]></content:encoded>
			<wfw:commentRss>http://www.crankberryblog.com/2009/stats-you-should-know-before-making-a-website/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Websites you should have bookmarked if you&#039;re a webmaster</title>
		<link>http://www.crankberryblog.com/2009/websites-you-should-have-bookmarked-if-youre-a-webmaster</link>
		<comments>http://www.crankberryblog.com/2009/websites-you-should-have-bookmarked-if-youre-a-webmaster#comments</comments>
		<pubDate>Mon, 02 Nov 2009 22:58:37 +0000</pubDate>
		<dc:creator>Jerry Low</dc:creator>
				<category><![CDATA[Tools]]></category>
		<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">http://www.crankberryblog.com/?p=258</guid>
		<description><![CDATA[If you not only own your website but also develop and maintain it yourself then you should understand how hard it is if there weren't some already developed tools and web resources to help you with your work. Here I've listed some of my favourite development resource sites and should be yours too for your developing moments. If you don't have them all bookmarked yet, DO IT NOW!

<img src="http://www.crankberryblog.com/images/bookmark-these-screenshot.jpg" />]]></description>
			<content:encoded><![CDATA[<p>If you not only own your website but also develop and maintain it yourself then you should understand how hard it is if there weren&#039;t some already developed tools and web resources to help you with your work. Here I&#039;ve listed some of my favourite development resource sites and should be yours too for your developing moments. If you don&#039;t have them all bookmarked yet, DO IT NOW!</p>
<p><a href="http://www.typetester.org/"><br />
<h3>Typetester</h3>
<p></a></p>
<p>Typetester is a website which allows you to test out fonts to see how they compare to to each other. This will allow you to test the font live and choose the one you want to use on your site.</p>
<p><a href="http://www.typetester.org/"><img src="http://www.crankberryblog.com/images/bookmark-these-typetester.jpg" /></a></p>
<p><a href="http://browsershots.org/"><br />
<h3>BrowserShots</h3>
<p></a></p>
<p>This is the resource for ultimate cross-browser compatibility building. BrowserShots allows you to take screenshots of your website so you can see what it looks like through various browsers and operating systems.</p>
<p><a href="http://browsershots.org/"><img src="http://www.crankberryblog.com/images/bookmark-these-browsershots.jpg" /></a></p>
<p><a href="http://validator.w3.org/"><br />
<h3>W3C Validator</h3>
<p></a></p>
<p>Run your site through W3C validator and it&#039;ll tell you if your HTML and Javascript codes are well structured. Good for building clean and proper codes.</p>
<p><a href="http://validator.w3.org/"><img src="http://www.crankberryblog.com/images/bookmark-these-w3c.jpg" /></a></p>
<p><a href="http://viewlike.us/"><br />
<h3>View Like Us</h3>
<p></a></p>
<p>View Like Us complements BrowserShots very well. This web tool allows you to quickly test your website viewport in various resolution sizes including Wii and iPhone screen resolutions.</p>
<p><a href="http://viewlike.us/"><img src="http://www.crankberryblog.com/images/bookmark-these-viewlikeus.jpg" /></a></p>
<p><a href="http://www.lipsum.com"><br />
<h3>Lorem Ipsum</h3>
<p></a></p>
<p>If you&#039;re just starting to build new sites, the best thing to have to fluff up your site is dummy text. Use the Lorem Ipsum generator to create various length of text to fill in those pages.</p>
<p><a href="http://www.lipsum.com"><img src="http://www.crankberryblog.com/images/bookmark-these-lorem.jpg" /></a></p>
<p><a href="http://www.shaboopie.com/"><br />
<h3>Shaboopie</h3>
<p></a></p>
<p>If you&#039;re not designing your own site and have no resources to hire somebody to do so then you should check out Shaboopie as they have a large selection for free vector logos to use.</p>
<p><a href="http://www.shaboopie.com/"><img src="http://www.crankberryblog.com/images/bookmark-these-logo.jpg" /></a></p>
<p><a href="http://www.iconarchive.com"><br />
<h3>Icon Archive</h3>
<p></a></p>
<p>Just like the excuse you have above, if you have no time to draw and you need great icons, just go to Icon Archive. They have a huge selection of free icons and the site is so easy to navigate.</p>
<p><a href="http://www.iconarchive.com"><img src="http://www.crankberryblog.com/images/bookmark-these-iconarchive.jpg" /></a></p>
<p><a href="http://www.bestwebframeworks.com/"><br />
<h3>Best Web Frameworks</h3>
<p></a></p>
<p>Best Web Frameworks is one of my favourites. Just select the web language you&#039;re using and check popular frameworks and compatibility.</p>
<p><a href="http://www.bestwebframeworks.com/"><img src="http://www.crankberryblog.com/images/bookmark-these-framework.jpg" /></a></p>
<p><a href="http://www.pixlr.com"><br />
<h3>Pixlr</h3>
<p></a></p>
<p>If you ever need to edit any images but don&#039;t have Photoshop handy, or Photoshop at all then you should use Pixlr. It is practically a tamed version of Photoshop online.</p>
<p><a href="http://www.pixlr.com"><img src="http://www.crankberryblog.com/images/bookmark-these-pixlr.jpg" /></a></p>
<p>What great things do you have in your pocket (nothing disgusting ok!)? Comment and share with the rest of the group.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.crankberryblog.com/2009/websites-you-should-have-bookmarked-if-youre-a-webmaster/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Generate rounded CSS corners without images</title>
		<link>http://www.crankberryblog.com/2009/generate-css-div-rounded-corners-without-images</link>
		<comments>http://www.crankberryblog.com/2009/generate-css-div-rounded-corners-without-images#comments</comments>
		<pubDate>Tue, 29 Sep 2009 23:13:53 +0000</pubDate>
		<dc:creator>Jerry Low</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Web Design]]></category>
		<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">http://www.crankberryblog.com/?p=156</guid>
		<description><![CDATA[<div class="excerpt_screen_right"><img src="http://www.crankberryblog.com/images/css-rounded-corners-sm.jpg" alt="CSS Rounded Corners Generator" /></div>I was looking at ways in which I could have built my websites differently today and came across the question. How can I guarantee my CSS rounded corners to be closer to 100% cross browser compatible. I came across a few sites with scripts and generators simplifying the tasks but most of them failed the browser test. I came up with a simple script that was simple and light. I'm not going to share the code. Now don't flame me yet. Instead I've made it easier for everybody. I've created the <a href="http://csscorners.crankberryblog.com">simple CSS rounded corners generator</a>.]]></description>
			<content:encoded><![CDATA[<p>I was looking at ways in which I could have built my websites differently today and came across the question. How can I guarantee my CSS rounded corners to be closer to 100% cross browser compatible. I came across a few sites with scripts and generators simplifying the tasks but most of them failed the browser test. I came up with a simple script that was simple and light. I&#039;m not going to share the code. Now don&#039;t flame me yet. Instead I&#039;ve made it easier for everybody. I&#039;ve created the <a href="http://csscorners.crankberryblog.com">simple CSS rounded corners generator</a>.</p>
<p>The result is really just&#8230; a rounded div box. Here&#039;s an example I quickly generated from the tool.<br />
<img src="http://www.crankberryblog.com/images/css-rounded-corners-screen.jpg" alt="CSS Screenshot" /></p>
<p>Have you opened the link yet? No? Open it up and I&#039;ll give a quick tour of it. The tool&#039;s very simple to use. All you have to do is configure four settings and it&#039;ll do the rest for you. The four settings are:</p>
<ol>
<li>Class Name</li>
<li>Background Color</li>
<li>Font Color</li>
<li>Roundness</li>
</ol>
<p>I&#039;ll just briefly touch on the class name and roundness. The remaining settings is kind of obvious. So the class name does not really need to be set <em>UNLESS</em> you have multiple rounded corner boxes that are different. If you&#039;re using the same boxes over and over again, that&#039;s fine but once you change style you&#039;ll have to create new classes so they don&#039;t over lap.</p>
<p>The current roundness settings are 1, 2, 4, 8px. These are the settings I believe looks best with most web design. Anymore will make your template look like a lot of circles.</p>
<p>So that&#039;s it, that&#039;s the tool I created for all of you. If you have any questions or feedback leave a line here and I&#039;ll attend to it. Cheers!</p>
<p>If you didn&#039;t find the link in the Article here it is again.<br />
The Tool: <a href="http://csscorners.crankberryblog.com"><strong>CSS Rounded Corners Generator</strong></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.crankberryblog.com/2009/generate-css-div-rounded-corners-without-images/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Removing bullets from WordPress default theme menu</title>
		<link>http://www.crankberryblog.com/2009/removing-bullets-from-wordpress-default-theme-menu</link>
		<comments>http://www.crankberryblog.com/2009/removing-bullets-from-wordpress-default-theme-menu#comments</comments>
		<pubDate>Mon, 21 Sep 2009 20:42:56 +0000</pubDate>
		<dc:creator>Jerry Low</dc:creator>
				<category><![CDATA[Web Development]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://localhost/ctest/?p=17</guid>
		<description><![CDATA[As I was setting up this blog I was disgusted by the bullets that were implemented to the menu on the right (they call it side bar). I thought to myself, no biggie, I'll just remove it when skinning/theming this thing. As I have built many themes for different forums in the past I believe this wouldn't be such a hard task. After some searching I have found <a title="Removing the WordPress sidebar bullets " href="http://www.lancelhoff.com/removing-the-wordpress-sidebar-bullets/" target="_blank">this article</a>, but by editing the CSS it did not work for me. So here I'm sharing a method to <em>hard code</em> out the bullets in the side bar of the default WordPress theme Kubrick.]]></description>
			<content:encoded><![CDATA[<p>As I was setting up this blog I was disgusted by the bullets that were implemented to the menu on the right (they call it side bar). I thought to myself, no biggie, I&#039;ll just remove it when skinning/theming this thing. As I have built many themes for different forums in the past I believe this wouldn&#039;t be such a hard task. After some searching I have found <a title="Removing the WordPress sidebar bullets " href="http://www.lancelhoff.com/removing-the-wordpress-sidebar-bullets/" target="_blank">this article</a>, but by editing the CSS it did not work for me. So here I&#039;m sharing a method to <em>hard code</em> out the bullets in the side bar of the default WordPress theme Kubrick.</p>
<p>Now this method is not recommended for those who are not comfortable or disturbed by the thought of &#034;editing code&#034;. Its really not all that complicated but if you&#039;re really not comfortable stop reading now and quit while you&#039;re ahead, I&#039;m sure there&#039;s other people out there ready to help.</p>
<p><strong>What will you get from this?</strong></p>
<p>In the end you should be able to successfully remove the bullets in the Pages, Archives, Categories, and Bookmarks inner section. These are what I&#039;ve named them, yours could vary. I&#039;m calling it the inner section because I didn&#039;t talk about how to remove the bullets in the title here, at this point I haven&#039;t gone through everything so I&#039;ll update every one when it happens.</p>
<p>So, with that said lets get started. Here is a list of files that we&#039;ll be editing so I recommend you make a backup prior to beginning just in case something goes wrong.</p>
<ul>
<li>wp-includes/classes.php</li>
<li>wp-content/themes/default/sidebar.php</li>
<li>wp-includes/bookmark-template.php</li>
</ul>
<p>Got that? Backed it up? Good! We&#039;ll start from the top, so the first bullets we&#039;ll remove is the Pages section. These are links to pages that you can create outside of your blog postings.</p>
<h3>Removing Bullets from the Pages Section</h3>
<p>Open wp-includes/classes.php, if your editor has a find function use it now. Find the line class Walker_Page. This is the class that we need to work in.</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw2">function</span> start_lvl<span class="br0">&#40;</span>&amp;<span class="re0">$output</span>, <span class="re0">$depth</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$indent</span> = <a href="http://www.php.net/str_repeat"><span class="kw3">str_repeat</span></a><span class="br0">&#40;</span><span class="st0">&quot;<span class="es0">\t</span>&quot;</span>, <span class="re0">$depth</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= <span class="st0">&quot;<span class="es0">\n</span>$indent&lt;ul&gt;<span class="es0">\n</span>&quot;</span>;<br />
<span class="br0">&#125;</span></div>
<p>In line 3 you can find the &lt;ul&gt;  we need to remove. So remove it. Now the we removed the opening tag we have to remove the closing tag. Scroll down a little bit and the closing tag is on line 3 of:</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw2">function</span> end_lvl<span class="br0">&#40;</span>&amp;<span class="re0">$output</span>, <span class="re0">$depth</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$indent</span> = <a href="http://www.php.net/str_repeat"><span class="kw3">str_repeat</span></a><span class="br0">&#40;</span><span class="st0">&quot;<span class="es0">\t</span>&quot;</span>, <span class="re0">$depth</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= <span class="st0">&quot;$indent&lt;/ul&gt;<span class="es0">\n</span>&quot;</span>;<br />
<span class="br0">&#125;</span></div>
<p>Ok, now stay where you are. Scroll down a little more and you&#039;ll come across the function start_el. Within the function look for a line that looks or is exactly like:</p>
<div class="dean_ch" style="white-space: wrap;"><span class="re0">$output</span> .= <span class="re0">$indent</span> . <span class="st0">&#039;&lt;li class=&quot;&#039;</span> . <span class="re0">$css_class</span> . <span class="st0">&#039;&quot;&gt;&lt;a href=&quot;&#039;</span> . get_page_link<span class="br0">&#40;</span><span class="re0">$page</span>-&gt;<span class="me1">ID</span><span class="br0">&#41;</span> . <span class="st0">&#039;&quot; title=&quot;&#039;</span> . esc_attr<span class="br0">&#40;</span>apply_filters<span class="br0">&#40;</span><span class="st0">&#039;the_title&#039;</span>, <span class="re0">$page</span>-&gt;<span class="me1">post_title</span><span class="br0">&#41;</span><span class="br0">&#41;</span> . <span class="st0">&#039;&quot;&gt;&#039;</span> . <span class="re0">$link_before</span> . apply_filters<span class="br0">&#40;</span><span class="st0">&#039;the_title&#039;</span>, <span class="re0">$page</span>-&gt;<span class="me1">post_title</span><span class="br0">&#41;</span> . <span class="re0">$link_after</span> . <span class="st0">&#039;&lt;/a&gt;&#039;</span>;</div>
<p>In this code here you&#039;ll have to remove the following code. Note: Don&#039;t remove the &#039; in the beginning.</p>
<div class="dean_ch" style="white-space: wrap;">&lt;li class=&quot;&#039; . $css_class . &#039;&quot;&gt;</div>
<p>What we just did was remove the opening &lt;li&gt; lets find and remove the closing one. Take a guess at where it is, you&#039;re right! Scroll down a little more and you&#039;ll find the missing piece of the puzzle. Within the func end_el you&#039;ll notice the &lt;/li&gt; in line two.</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw2">function</span> end_el<span class="br0">&#40;</span>&amp;<span class="re0">$output</span>, <span class="re0">$page</span>, <span class="re0">$depth</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= <span class="st0">&quot;&lt;/li&gt;<span class="es0">\n</span>&quot;</span>;<br />
<span class="br0">&#125;</span></div>
<p>Instead of just removing this one, replace it with &lt;br /&gt;. This will add a line break between page listing.</p>
<h3>Removing Bullets from the Category Section</h3>
<p>At this point you should have already removed the bullets for the page section. Has it happened? If not you should spend some time in the first part of the article first. Next we will work on the category section, so in the same file find:</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw2">&lt;?php</span> wp_list_categories<span class="br0">&#40;</span><span class="st0">&#039;show_count=1&amp;title_li=&lt;h2&gt;Categories&lt;/h2&gt;&#039;</span><span class="br0">&#41;</span>; <span class="kw2">?&gt;</span></div>
<p>and change that to</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw2">&lt;?php</span> wp_list_categories<span class="br0">&#40;</span><span class="st0">&#039;style=none&amp;show_count=1&amp;title_li=&lt;h2&gt;Categories&lt;/h2&gt;&#039;</span><span class="br0">&#41;</span>; <span class="kw2">?&gt;</span></div>
<p>Basically what we have done is passed on the argument that the style is none (default is list).</p>
<h3>Removing Bullets from the Archive Section</h3>
<p>If you&#039;ve gotten this far, congratulations you have successfully removed the bullets in the categories section. If you have already guessed it by now yes the next step is pretty much the same but in this case they named it something else. To remove the bullets from the archive list find (also in sidebar.php):</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw2">&lt;?php</span> wp_get_archives<span class="br0">&#40;</span><span class="st0">&#039;type=monthly&#039;</span><span class="br0">&#41;</span>; <span class="kw2">?&gt;</span></div>
<p>and change it to:</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw2">&lt;?php</span> wp_get_archives<span class="br0">&#40;</span><span class="st0">&#039;type=monthly&amp;format=none&#039;</span><span class="br0">&#41;</span>; <span class="kw2">?&gt;</span></div>
<p>Basically they changed the argument from style to format.</p>
<h3>Removing Bullets from the Links Section</h3>
<p>Now you&#039;re only left with removing the bullets in the links section also known as the bookmark section. This one was hard to pass the argument, maybe somebody could suggest a way, but here&#039;s what I did. Open up wp-includes/bookmark-template.php. Find function wp_list_bookmarks. We&#039;ll remove the &lt;li&gt;&lt;&#47li&gt; tags first since it comes up first. The first thing that comes up in the function is an array.</p>
<div class="dean_ch" style="white-space: wrap;">&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$defaults</span> = <a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;orderby&#039;</span> =&gt; <span class="st0">&#039;name&#039;</span>, <span class="st0">&#039;order&#039;</span> =&gt; <span class="st0">&#039;ASC&#039;</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;limit&#039;</span> =&gt; <span class="nu0">-1</span>, <span class="st0">&#039;category&#039;</span> =&gt; <span class="st0">&#034;</span>, <span class="st0">&#039;exclude_category&#039;</span> =&gt; <span class="st0">&#034;</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;category_name&#039;</span> =&gt; <span class="st0">&#034;</span>, <span class="st0">&#039;hide_invisible&#039;</span> =&gt; <span class="nu0">1</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;show_updated&#039;</span> =&gt; <span class="nu0">0</span>, <span class="st0">&#039;echo&#039;</span> =&gt; <span class="nu0">1</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;categorize&#039;</span> =&gt; <span class="nu0">1</span>, <span class="st0">&#039;title_li&#039;</span> =&gt; __<span class="br0">&#40;</span><span class="st0">&#039;Bookmarks&#039;</span><span class="br0">&#41;</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;title_before&#039;</span> =&gt; <span class="st0">&#039;&lt;h2&gt;&#039;</span>, <span class="st0">&#039;title_after&#039;</span> =&gt; <span class="st0">&#039;&lt;/h2&gt;&#039;</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;category_orderby&#039;</span> =&gt; <span class="st0">&#039;name&#039;</span>, <span class="st0">&#039;category_order&#039;</span> =&gt; <span class="st0">&#039;ASC&#039;</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;class&#039;</span> =&gt; <span class="st0">&#039;linkcat&#039;</span>, <span class="st0">&#039;category_before&#039;</span> =&gt; <span class="st0">&#039;&lt;li id=&quot;%id&quot; class=&quot;%class&quot;&gt;&#039;</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;category_after&#039;</span> =&gt; <span class="st0">&#039;&lt;/li&gt;&#039;</span><br />
<span class="br0">&#41;</span>;</div>
<p>The last two lines you&#039;ll see category_before => and category_after =>. Clear everything inside of the single quotes that they are pointing to. So you should be left with &#039;category_before&#039; => &#034; and &#039;category_after&#039; => &#034;. Go down a bit further and you&#039;ll find this piece of code:</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw1">if</span> <span class="br0">&#40;</span> <span class="re0">$categorize</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; <span class="co1">//Split the bookmarks into ul&#039;s for each category</span><br />
&nbsp; &nbsp; <span class="re0">$cats</span> = get_terms<span class="br0">&#40;</span><span class="st0">&#039;link_category&#039;</span>, <a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&#039;name__like&#039;</span> =&gt; <span class="re0">$category_name</span>, <span class="st0">&#039;include&#039;</span> =&gt; <span class="re0">$category</span>, <span class="st0">&#039;exclude&#039;</span> =&gt; <span class="re0">$exclude_category</span>, <span class="st0">&#039;orderby&#039;</span> =&gt; <span class="re0">$category_orderby</span>, <span class="st0">&#039;order&#039;</span> =&gt; <span class="re0">$category_order</span>, <span class="st0">&#039;hierarchical&#039;</span> =&gt; <span class="nu0">0</span><span class="br0">&#41;</span><span class="br0">&#41;</span>;</p>
<p>&nbsp; &nbsp; <span class="kw1">foreach</span> <span class="br0">&#40;</span> <span class="br0">&#40;</span><a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#41;</span> <span class="re0">$cats</span> <span class="kw1">as</span> <span class="re0">$cat</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$params</span> = <a href="http://www.php.net/array_merge"><span class="kw3">array_merge</span></a><span class="br0">&#40;</span><span class="re0">$r</span>, <a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&#039;category&#039;</span>=&gt;<span class="re0">$cat</span>-&gt;<span class="me1">term_id</span><span class="br0">&#41;</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$bookmarks</span> = get_bookmarks<span class="br0">&#40;</span><span class="re0">$params</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">if</span> <span class="br0">&#40;</span> <a href="http://www.php.net/empty"><span class="kw3">empty</span></a><span class="br0">&#40;</span><span class="re0">$bookmarks</span><span class="br0">&#41;</span> <span class="br0">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">continue</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= <a href="http://www.php.net/str_replace"><span class="kw3">str_replace</span></a><span class="br0">&#40;</span><a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&#039;%id&#039;</span>, <span class="st0">&#039;%class&#039;</span><span class="br0">&#41;</span>, <a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&quot;linkcat-$cat-&gt;term_id&quot;</span>, <span class="re0">$class</span><span class="br0">&#41;</span>, <span class="re0">$category_before</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$catname</span> = apply_filters<span class="br0">&#40;</span> <span class="st0">&quot;link_category&quot;</span>, <span class="re0">$cat</span>-&gt;<span class="me1">name</span> <span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= <span class="st0">&quot;$title_before$catname$title_after<span class="es0">\n</span><span class="es0">\t</span>&lt;ul class=&#039;xoxo blogroll&#039;&gt;<span class="es0">\n</span>&quot;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= _walk_bookmarks<span class="br0">&#40;</span><span class="re0">$bookmarks</span>, <span class="re0">$r</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= <span class="st0">&quot;<span class="es0">\n</span><span class="es0">\t</span>&lt;/ul&gt;<span class="es0">\n</span>$category_after<span class="es0">\n</span>&quot;</span>;<br />
&nbsp; &nbsp; <span class="br0">&#125;</span><br />
<span class="br0">&#125;</span> <span class="kw1">else</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; <span class="co1">//output one single list using title_li for the title</span><br />
&nbsp; &nbsp; <span class="re0">$bookmarks</span> = get_bookmarks<span class="br0">&#40;</span><span class="re0">$r</span><span class="br0">&#41;</span>;</p>
<p>&nbsp; &nbsp; <span class="kw1">if</span> <span class="br0">&#40;</span> !<a href="http://www.php.net/empty"><span class="kw3">empty</span></a><span class="br0">&#40;</span><span class="re0">$bookmarks</span><span class="br0">&#41;</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">if</span> <span class="br0">&#40;</span> !<a href="http://www.php.net/empty"><span class="kw3">empty</span></a><span class="br0">&#40;</span> <span class="re0">$title_li</span> <span class="br0">&#41;</span> <span class="br0">&#41;</span><span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= <a href="http://www.php.net/str_replace"><span class="kw3">str_replace</span></a><span class="br0">&#40;</span><a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&#039;%id&#039;</span>, <span class="st0">&#039;%class&#039;</span><span class="br0">&#41;</span>, <a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&quot;linkcat-$category&quot;</span>, <span class="re0">$class</span><span class="br0">&#41;</span>, <span class="re0">$category_before</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= <span class="st0">&quot;$title_before$title_li$title_after<span class="es0">\n</span><span class="es0">\t</span>&lt;ul class=&#039;xoxo blogroll&#039;&gt;<span class="es0">\n</span>&quot;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= _walk_bookmarks<span class="br0">&#40;</span><span class="re0">$bookmarks</span>, <span class="re0">$r</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= <span class="st0">&quot;<span class="es0">\n</span><span class="es0">\t</span>&lt;/ul&gt;<span class="es0">\n</span>$category_after<span class="es0">\n</span>&quot;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="br0">&#125;</span> <span class="kw1">else</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= _walk_bookmarks<span class="br0">&#40;</span><span class="re0">$bookmarks</span>, <span class="re0">$r</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="br0">&#125;</span><br />
&nbsp; &nbsp; <span class="br0">&#125;</span><br />
<span class="br0">&#125;</span></div>
<p>Do not be scared of its ginormous size. You can either go through and remove the two pairs of &lt;ul&gt;&lt;&#47ul&gt; or just comment them out. As I said they occur twice for different situations. Commenting it out will make it look like so:</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw1">if</span> <span class="br0">&#40;</span> <span class="re0">$categorize</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; <span class="co1">//Split the bookmarks into ul&#039;s for each category</span><br />
&nbsp; &nbsp; <span class="re0">$cats</span> = get_terms<span class="br0">&#40;</span><span class="st0">&#039;link_category&#039;</span>, <a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&#039;name__like&#039;</span> =&gt; <span class="re0">$category_name</span>, <span class="st0">&#039;include&#039;</span> =&gt; <span class="re0">$category</span>, <span class="st0">&#039;exclude&#039;</span> =&gt; <span class="re0">$exclude_category</span>, <span class="st0">&#039;orderby&#039;</span> =&gt; <span class="re0">$category_orderby</span>, <span class="st0">&#039;order&#039;</span> =&gt; <span class="re0">$category_order</span>, <span class="st0">&#039;hierarchical&#039;</span> =&gt; <span class="nu0">0</span><span class="br0">&#41;</span><span class="br0">&#41;</span>;</p>
<p>&nbsp; &nbsp; <span class="kw1">foreach</span> <span class="br0">&#40;</span> <span class="br0">&#40;</span><a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#41;</span> <span class="re0">$cats</span> <span class="kw1">as</span> <span class="re0">$cat</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$params</span> = <a href="http://www.php.net/array_merge"><span class="kw3">array_merge</span></a><span class="br0">&#40;</span><span class="re0">$r</span>, <a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&#039;category&#039;</span>=&gt;<span class="re0">$cat</span>-&gt;<span class="me1">term_id</span><span class="br0">&#41;</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$bookmarks</span> = get_bookmarks<span class="br0">&#40;</span><span class="re0">$params</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">if</span> <span class="br0">&#40;</span> <a href="http://www.php.net/empty"><span class="kw3">empty</span></a><span class="br0">&#40;</span><span class="re0">$bookmarks</span><span class="br0">&#41;</span> <span class="br0">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">continue</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= <a href="http://www.php.net/str_replace"><span class="kw3">str_replace</span></a><span class="br0">&#40;</span><a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&#039;%id&#039;</span>, <span class="st0">&#039;%class&#039;</span><span class="br0">&#41;</span>, <a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&quot;linkcat-$cat-&gt;term_id&quot;</span>, <span class="re0">$class</span><span class="br0">&#41;</span>, <span class="re0">$category_before</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$catname</span> = apply_filters<span class="br0">&#40;</span> <span class="st0">&quot;link_category&quot;</span>, <span class="re0">$cat</span>-&gt;<span class="me1">name</span> <span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="co1">//$output .= &quot;$title_before$catname$title_after\n\t&lt;ul class=&#039;xoxo blogroll&#039;&gt;\n&quot;;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= _walk_bookmarks<span class="br0">&#40;</span><span class="re0">$bookmarks</span>, <span class="re0">$r</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="co1">//$output .= &quot;\n\t&lt;/ul&gt;\n$category_after\n&quot;;</span><br />
&nbsp; &nbsp; <span class="br0">&#125;</span><br />
<span class="br0">&#125;</span> <span class="kw1">else</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; <span class="co1">//output one single list using title_li for the title</span><br />
&nbsp; &nbsp; <span class="re0">$bookmarks</span> = get_bookmarks<span class="br0">&#40;</span><span class="re0">$r</span><span class="br0">&#41;</span>;</p>
<p>&nbsp; &nbsp; <span class="kw1">if</span> <span class="br0">&#40;</span> !<a href="http://www.php.net/empty"><span class="kw3">empty</span></a><span class="br0">&#40;</span><span class="re0">$bookmarks</span><span class="br0">&#41;</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">if</span> <span class="br0">&#40;</span> !<a href="http://www.php.net/empty"><span class="kw3">empty</span></a><span class="br0">&#40;</span> <span class="re0">$title_li</span> <span class="br0">&#41;</span> <span class="br0">&#41;</span><span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= <a href="http://www.php.net/str_replace"><span class="kw3">str_replace</span></a><span class="br0">&#40;</span><a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&#039;%id&#039;</span>, <span class="st0">&#039;%class&#039;</span><span class="br0">&#41;</span>, <a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><span class="st0">&quot;linkcat-$category&quot;</span>, <span class="re0">$class</span><span class="br0">&#41;</span>, <span class="re0">$category_before</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="co1">//$output .= &quot;$title_before$title_li$title_after\n\t&lt;ul class=&#039;xoxo blogroll&#039;&gt;\n&quot;;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= _walk_bookmarks<span class="br0">&#40;</span><span class="re0">$bookmarks</span>, <span class="re0">$r</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="co1">//$output .= &quot;\n\t&lt;/ul&gt;\n$category_after\n&quot;;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="br0">&#125;</span> <span class="kw1">else</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="re0">$output</span> .= _walk_bookmarks<span class="br0">&#40;</span><span class="re0">$bookmarks</span>, <span class="re0">$r</span><span class="br0">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="br0">&#125;</span><br />
&nbsp; &nbsp; <span class="br0">&#125;</span><br />
<span class="br0">&#125;</span></div>
<p>Scroll up a bit in the same file and you&#039;ll find the last piece of the puzzle. Just edit the code in function _walk_bookmarks().</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw2">function</span> _walk_bookmarks<span class="br0">&#40;</span><span class="re0">$bookmarks</span>, <span class="re0">$args</span> = <span class="st0">&#034;</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
<span class="re0">$defaults</span> = <a href="http://www.php.net/array"><span class="kw3">array</span></a><span class="br0">&#40;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;show_updated&#039;</span> =&gt; <span class="nu0">0</span>, <span class="st0">&#039;show_description&#039;</span> =&gt; <span class="nu0">0</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;show_images&#039;</span> =&gt; <span class="nu0">1</span>, <span class="st0">&#039;show_name&#039;</span> =&gt; <span class="nu0">0</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;before&#039;</span> =&gt; <span class="st0">&#039;&lt;li&gt;&#039;</span>, <span class="st0">&#039;after&#039;</span> =&gt; <span class="st0">&#039;&lt;/li&gt;&#039;</span>, <span class="st0">&#039;between&#039;</span> =&gt; <span class="st0">&quot;<span class="es0">\n</span>&quot;</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="st0">&#039;show_rating&#039;</span> =&gt; <span class="nu0">0</span>, <span class="st0">&#039;link_before&#039;</span> =&gt; <span class="st0">&#034;</span>, <span class="st0">&#039;link_after&#039;</span> =&gt; <span class="st0">&#034;</span><br />
<span class="br0">&#41;</span>;</div>
<p>Change the &lt;li&gt;&lt;&#47li&gt; to &#034; or for me I changed the &#039;after&#039; =&gt; &#034; to &#039;after&#039; =&gt; &#039;&lt;BR /&gt;&#039;. Just to have the space in there.</p>
<p>And there you have it you have successfully hard coded the bullets out. If you ever want them back just replace all of your files with the backed up ones. Once again I just want to remind you that I&#039;ve only used this method because the modifying the styles didn&#039;t work for me. Do whatever is easiest and works.</p>
<h3>Bonus: Removing Bullets from the Register Panel</h3>
<p>As a bonus feature I&#039;ll throw in &#034;how to remove bullets from the register panel&#034; for free. Its very simple, in your sidebar.php file find:</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw2">&lt;?php</span> wp_register<span class="br0">&#40;</span><span class="br0">&#41;</span>; <span class="kw2">?&gt;</span></div>
<p>Just put into the brackets &#034;,&#034; like so:</p>
<div class="dean_ch" style="white-space: wrap;"><span class="kw2">&lt;?php</span> wp_register<span class="br0">&#40;</span><span class="st0">&#034;</span> ,<span class="st0">&#034;</span><span class="br0">&#41;</span>; <span class="kw2">?&gt;</span></div>
]]></content:encoded>
			<wfw:commentRss>http://www.crankberryblog.com/2009/removing-bullets-from-wordpress-default-theme-menu/feed</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
	</channel>
</rss>
