Jump to content

daniel-not-dan

Members
  • Posts

    40
  • Joined

  • Last visited

Everything posted by daniel-not-dan

  1. Yes it exists and the permission is set to 777. Not sure if this is helpful/relevant, but I only just migrated it from my local server to the host server last night. I just copied the files to the host server, and changed the config.php file to connect to the correct server. Is this possibly something that could be causing the error? EDIT: Just checked the XML sitemap on my local install and it is working there.
  2. Hi there - I'm having a little trouble getting this to work. I'm getting the same error that was mentioned earlier, namely this: Error: Exception: Unable to create path: /f5/thesharktankproducts/public/site/assets/cache/MarkupCache/MarkupSitemapXML/ (in /f5/thesharktankproducts/public/wire/core/CacheFile.php line 62) My site/assets/cache folder's permissions are currently set to 777. I also uninstalled Markup Cache and Markup XML, then reinstalled them (Cache first, and newest version of XML), with no luck. I'm running PW 2.3.0. I have what I think is the PW default site-map available here: http://thesharktankproducts.com/site-map/ but that's not readable by Google Webmaster Tools. I would be very grateful for any insights. Thanks!
  3. So after everyone's help on this, I wanted to go a little further and make the number of columns within the div.row variable to some degree. I'd like the option to display the products either two-across (which we've already accomplished) or three-across, which hurt my brain as soon as I tried to tackle it using the method above. So instead, here's what I came up with which should work for any number of columns across a 12-column grid setup. $numColumns = "4-columns"; // For a 3-across layout, given a 12-column grid. $magicNumber = 12 / $numColumns; //This will be the magic number at which the row closes itself. $lastProduct = $productList->last(); $counter = 1 foreach ($productList as $product) { if ($counter == 1) { echo "<div class = 'row'>"; //This is the first one, so open the div.row } echo "<div class = '$numColumns'>$product</div>"; if ($counter == $magicNumber || $product == $lastProduct) { echo "</div>" //This is the last one in the row, so close the div.row $counter = 0 //Reset to 0, knowing the next step will set it back to 1, so that the new row will open. } $counter++; } This allows me to pass in a variable ($numColumns) that says "I want these products to display thismany across." For my money, this seems like the simplest solution. Anyone think of any improvements?
  4. That worked, too - and yes, it's simpler. So, the $key is basically just a counter? I had it print the $key for each product next to the title and it just looked like sequential integers going up from 0. Is that the basic idea?
  5. Awesome. I'm a PHP noob, so some of that made sense... enough of it so that I was able to get it to work anyway! Here's the basic outline of it: $lastProduct = $productList->last(); $counter = 1; foreach ($productList as $product) { if($counter % 2 != 0) { echo "<div class = 'row'>"; //item is odd, so open the div.row } //echo the product echo "<div class = '6-columns'>"; echo "<div>$product</div>"; echo "</div>"; if($counter % 2 == 0) || $product == $lastProduct { echo "</div>" ; //item is even (or list is complete), so close the div.row } $counter = $count + 1; } I wasn't sure how to use the getItemKey() method, so if anyone feels like elaborating on that, I'm once again all ears! Thanks so much, diogo!
  6. Hi everyone! Got a puzzle here for you, and if you're able to solve it - I'm all ears! I'm trying to create a grid using PHP that looks roughly like this: <div class = "row"> <div class = "6-columns"> <div>Product</div> </div> <div class = "6-columns"> <div>Product</div> </div> </div> <div class = "row"> <div class = "6-columns"> <div>Product</div> </div> <div class = "6-columns"> <div>Product</div> </div> </div> The Products here are being collected from a group of pages. I'm able to get them to display, but here's the problem... I need to Loop thru them two-at-a-time so I can add a new "row" before each new group of two 6-column divs. Here's what I have so far (in overly-simplified form): echo "<div class = 'row'>"; foreach ($productList as $product) { echo "<div class = '6-columns'><div>$product</div></div>"; } echo "</div>" See my issue? The output from this is something like: <div class = "row"> <div class = "6-columns"> <div>Product</div> </div> <div class = "6-columns"> <div>Product</div> </div> <div class = "6-columns"> <div>Product</div> </div> <div class = "6-columns"> <div>Product</div> </div> </div> I'm sure I need some kind of do while loop or something in there, but I can't seem to get the sequence right of what should go where so I can do ONE row, then TWO products, then ONE row, then TWO products, etc. So, no, this is not really a PW issue, but I thought someone here might like a crack at helping me solve this! All the best, Daniel
  7. SOLVED: I had some Pages in the Trash that were still "using" those templates. I emptied the Trash and now I can delete them.
  8. I just did a fresh install of PW 2.3 on a new database (local install) and I'm trying to clear out the default pages/templates/fields/etc. I deleted all the pages (except Home), all the fields I don't want, and am working on the Templates. Even though I only have a Home page now, when I look at the Template admin page, I see that it still thinks Site Search and Sitemap are being used by 1 page each. For that matter, it says basic-page is being used by 5 pages. I am unable to delete any of these templates, and unable to figure out what other pages might be using these templates. Did I do something out of order? Is there something else I'm missing? If further info is required, I'm happy to provide it. (Please feel free to yell at me if the answer is so bleeding obvious that I cannot be taken seriously!)
  9. Thanks, gents! I'm inclined to follow the advice from the thread diogo linked to. That seems to be a more accurate answer to what I was asking, but I love hearing the variety of solutions! I will have to play around with this for the next few hours...
  10. Just curious... I noticed in Joss's Bootwire Demo Profile that you are able to set the header background image and the color of the header text in his Settings page. Looking at his header.inc file, I see that when the header is loaded, the color & image you select goes into the HTML by way of an inline style tag: <div class="hero-unit" style="background:url(<?php echo $pages->get("/content-management/site-settings/")->site_header_banner->url; ?>) no-repeat;color:#<?php echo $pages->get("/content-management/site-settings/")->site_header_text_color; ?>;"> My question is (as someone not super familiar with either PHP or javascript) - would there be a way to do that but without putting it into the template file? In other words, can the Settings page control the CSS file, either directly, or using some javascripty thing? I have no problem doing it this way, but as someone who's been told that style and structure need to be separate, I'm curious if it's possible. Especially if, say, I wanted to create a Setting that would change ALL the headers on the site to a different font-family. If there's already a topic that addresses this, feel free to just point me in that direction - I couldn't find it. Thanks!
  11. Thanks, @Wanze! Follow-up question: I have a class ("half") assigned to the list - how would I assign that class to the unordered list created by the textformatter module? I was able to easily output the entire <ul> and all the <li>'s just by using: <?=$page->finplan_assistance_list_items ?>, but if I want to "break in" and use that class on the <ul>, does anyone have ideas for that?
  12. Hi there - this is more out of curiosity than necessity, but here's my question. (I'm more of a designer than a developer, so sorry in advance if the answer is super-obvious.) I want to create a field in a template where my client can enter a list of items to display in one section the site. For reference, I'm working on this: http://houchinswitt.com/new-site/#finplan. Right now, the first list is being populated with a Repeater field (using a single text line), but I feel like that's surplus to requirement. What I ultimately want is a simpler, fool-proof way of creating a list without my client having to use the TinyMCE list tool. What I'd MOST like is something like what happens when you create a Select field in the PW admin, and on the Details tab it gives you a text box where you just put in one item, hit enter, put in another item, hit enter, etc. If it's possible to do that (which I assume it is!) - can someone give an example of how I would break those values out of the database for presentation on the page? I know this is probably over-complicating the issue, but, like I said, I'm curious... and I'm always looking for ways to keep things fool-proof for my clients. The Repeater field works, it's just overly fussy for a job this small.
  13. Thanks so much Joss - that is very helpful. And it worked like a charm! Finding my way...
  14. Hi everyone! First time poster, long time listener... It's been a joy discovering PW over the last week or two - love the support forums and the system in general! I'm building my first site right now and am having an issue where the TinyMCE editor is stripping my <sup></sup> tags. I need to have "TM" as a superscript so that my text doesn't look like this: CERTIFIED FINANCIAL PLANNERTM, but instead looks like this: CERTIFIED FINANCIAL PLANNERTM. I see that the editor here in the forums has the superscript and subscript buttons, but can't work out how to include them in the TinyMCE editor within the website interface. Any help with this? Thanks!
×
×
  • Create New...