Jump to content

ShaneFoster

Members
  • Posts

    13
  • Joined

  • Last visited

Profile Information

  • Gender
    Not Telling

ShaneFoster's Achievements

Jr. Member

Jr. Member (3/6)

1

Reputation

  1. @szabesz You're a genius! I probably should have figured that out Thanks so much for the help on this. I was getting pretty frustrated by it!
  2. @szabez Thanks so much for clarifying! It's interesting that I have that enabled. I tried disabling it and enabling it again with no luck My setup looks like so... HTML Entity Encoder Enabled: https://www.dropbox.com/s/qvhus1nnfgm1vdg/Screen%20Shot%202016-02-18%20at%2011.47.30%20AM.png?dl=0 Text Area Input: https://www.dropbox.com/s/bgwzfuuuxckfflw/Screen%20Shot%202016-02-18%20at%2011.46.46%20AM.png?dl=0 Text Area Output: https://www.dropbox.com/s/dtgz3ypwlmqbq17/Screen%20Shot%202016-02-18%20at%2011.47.06%20AM.png?dl=0
  3. I am also experiencing the issue with <p> tags showing with my text when using CKeditor. I can't seem to figure out where to verify that I have "convert to HTML entities" selected. Can anyone help me out? Thanks in advance! Shane
  4. Hi All, I have a template with a large header image (2,000px+). I want that image to span the entire browser window width, assuming the image is large enough on a user's screen. When I upload the image via the admin UI it seems to always be automatically resized (to 1140px) in width, in this case. I am building the site using the Processwire Blog Profile. I am not sure where this automated resize is occurring. Can anyone point me in the correct direction? I want the user to be able to upload the images using the admin UI, rather than me hard-coding the images in the header. Thanks in advance to anyone that can offer some advice. I really appreciate it. Shane
  5. I see. That's about what I expected. That definitely sounds easy enough. I'd be more than happy to test the module. The user access system shouldn't be an issue for me with either of these sites. Thanks for making me aware of that though Thanks again, Shane
  6. Perfect. Thanks, Ryan! Is there an official doc on upgrading from 2.0 -> 2.1? I see a few things in the forum. It seems like it should be fairly straight forward. I thought I'd check before moving forward, just in case I miss something. Thanks again! Best, Shane
  7. Man, you guys are GOOD For some reason the "Select the roles that may view this page." check box was not checked. I'm assuming this is checked by Default. It looks like it is on all my other pages. I must have unchecked it by accident, like a moron. Looks like it's working as expected now. As always, thanks so much for the prompt response. It's mind blowing to see such amazing support on a small (but I'm sure soon to be huge) open source project. -Shane
  8. Hi, I'm experiencing a strange error when trying to query some child posts from a parent page/template. I have a Projects page that contains multiple child "Project" pages.The Project pages are based on the "project" template. The parent "Projects" page is based on the "Projects" template. When I view the "Projects" page of my site I see the following error returned: Viewable at: http://cougar.showtimedesigner.com/projects "The page you were looking for is not found. Please use our search engine or navigation above to find the page." However, if I login as site admin and resave the "Projects" page, then view my site again, the "Projects" page loads as expected. It seems I'm obviously querying the data correctly. I can get it to work, but only after I login and resave the "Projects" page using "Save Page". It seems as if it's a strange caching issue. Anyone have any thoughts on why this error occurs and why I have to resave the page to get it to display correctly? I'll post the code for each page below. Parent Projects Page Template <?php // Pull Child Projects from Projects Template $projects = $pages->get("/projects/")->find("template=project"); foreach($projects as $project) { ?> <div class="project-info-wrap"> <?php // Grab Project Images foreach($project->images as $img) { $t = $img->size(250, 250); } echo "<img src='{$t->url}' alt='{$t->description}' />"; ?> <div class='project-info'> <h2><?php echo $project->title; ?></h2> <ul> <li class="project-budget"><?php echo $project->project_budget; ?></li> <li class="project-company"><?php echo $project->project_company; ?></li> </ul> <p><?php echo $project->body; ?></p> </div> </div> <?php } ?> Child Project Page Template <h2><?php echo $page->title; ?></h2> <div class="project-info-wrap"> <?php foreach($page->images as $img) { $t = $img->size(250, 250); echo "<img src='{$t->url}' alt='{$t->description}' />"; } ?> <div class="project-info"> <ul> <li class="project-cost"><?php echo $page->project_budget; ?></li> <li class="project-company"><?php echo $page->project_company; ?></li> </ul> <p><?php echo $page->body; ?></p> </div> </div> Thanks in advance for your help!
  9. Hi Ryan, I added more parameters to my find() method to make it more specific. That did the trick! I now use: $work = $pages->find("parent=/work/web/ ,template=work_web, sort=-date"); Everything now works as expected. Thanks for much for taking the time to help me out on this. I really do appreciate it. Quick random question; do you guys have an account for "Donations" for Processwire? I'd hope that people would be willing to donate to a project with this much promise. I know I would.
  10. Thank you to both of you for the responses. I updated my code, based on your response, Ryan. I double-checked that I changed the "Maximum Files Allowed" for both image fields (work_thumb, work_full) to be one. My new code looks like the below (I didn't add the if statement to check for image as suggested yet, but I will): <?php $work = $pages->find("template=work_web, sort=-date"); foreach($work as $web_work) { $image = $web_work->work_thumb->first(); echo "<li><a title='{$web_work->title}' href='{$image->url}'><img src='{$image->url}' alt='{$web_work->title}'></a></li>"; } ?> Running this returns the following error (in DEBUG mode): Fatal error: Call to a member function first() on a non-object in /home2/showtim1/public_html/beta/site/templates/work.php on line 15 I made calls to a few other field types in this template to test, like "work_date", title and body. These all return the correct data. It seems to be the custom image fields that I can't query correctly. Any other ideas?
  11. Hi All, I have what I'm sure is a simple question for an experienced Processwire user. I am simply trying to render a custom image field in my template. For example, I have a page and template titled "work" that is querying data from a child template titled, "web_work" I have created. This "web_work" template contains two different custom image fields. One titled, "work_thumb", and the other being, "work_full". These simply display a thumbnail and full-size version of two images. For the general "Work" page and template I simply want to render the thumbnails of my Web work. A pretty standard request for an online portfolio. I can't seem to figure out how to query the full path of the image field. As of right now I have the below: $work = $pages->find("template=work_web, sort=-date"); foreach($work as $web_work) { $image = $web_work->work_thumb; echo '<pre>'; echo print_r(array_keys($image)); echo '</pre>'; echo "<li><a title='{$web_work->title}' href='{$image->url}'><img src='{$image->url}' alt='{$web_work->title}'></a></li>"; } The $image->url query only seems to display the folder containing the image file, not the actual image file name. It seems I need to somehow append the basename or filename to this query. I may be way off in my approach. I've tried to find a solution in the API and in the forums. I can't seem to figure it out. Hopefully I have explained this well enough. Let me know if more information is needed. Thanks in advance for any help anyone can provide!
  12. Thanks for the prompt responses, guys! I'll give your suggestions a try in a little while. I'll report back with my resolution. Thanks, again.
  13. Hi, I followed the directions to upgrade at, http://processwire.com/talk/index.php?topic=58.0. Now, when I view my site I see the error: "Unable to complete this request due to an error". I turned Debug mode on. I now see: Fatal error: Exception: Unknown column 'templates.flags' in 'field list' SELECT templates.id,templates.name,templates.fieldgroups_id,templates.flags,templates.cache_time,templates.data FROM `templates` ORDER BY templates.name (in C:\new_wamp\wamp\www\pwire2\wire\core\Database.php line 72) #0 C:\new_wamp\wamp\www\pwire2\wire\core\SaveableItems.php(132): Database->query(Object(DatabaseQuerySelect)) #1 [internal function]: WireSaveableItems->___load(Object(TemplatesArray)) #2 C:\new_wamp\wamp\www\pwire2\wire\core\Wire.php(267): call_user_func_array(Array, Array) #3 C:\new_wamp\wamp\www\pwire2\wire\core\Wire.php(229): Wire->runHooks('load', Array) #4 [internal function]: Wire->__call('load', Array) #5 C:\new_wamp\wamp\www\pwire2\wire\core\Templates.php(83): Templates->load(Object(TemplatesArray)) #6 C:\new_wamp\wamp\www\pwire2\wire\core\ProcessWire.php(116): Templates->init() #7 C:\new_wamp\wamp\www\pwire2\wire\core\ProcessWire.php(45): ProcessWire->load(Object(Config)) #8 C:\new_wamp\wamp\www\pwire2\index.php(151): Proce in C:\new_wamp\wamp\www\pwire2\index.php on line 186 This error message was shown because the site is in DEBUG mode. Even with this message I can't seem to debug what's causing the issue. It occurs every time I upload the 2.1 /wire folder and overwrite my old /wire version from 2.0. I have tried multiple times, but I can't seem to avoid this error. I searched the forums. I didn't find any similar issues. This is my last attempt to figure this out. I'm at a loss right now. Thanks in advance to anyone that can provide some insight! Shane
×
×
  • Create New...