Jump to content


everfreecreative

Member Since 26 Feb 2012
Offline Last Active Yesterday, 08:41 PM
-----

Topics I've Started

Weird Image Error

10 May 2013 - 12:53 PM

I have email error notifications turned on for one of my recent ProcessWire sites and have been receiving the following error alert:

 

 

Error: 


Call to a member function height() on a non-object (line 292 of /home/teachct/public_html/wire/modules/Process/ProcessPageEditImageSelect/ProcessPageEditImageSelect.module)

 

 

I'm not sure exactly where this is happening because the client has not reported any visible issue. However, I'm wondering whether this might be a familiar error to anyone (or something that might make sense to Ryan :))

 

Thanks!


New ProcessWire site with Shopping Cart

19 March 2013 - 02:49 PM

We just launched a new e-commerce website built off of ProcessWire. We worked off of Apeisa's shopping cart module as a base and were able to get the system integrated with Authorize.net's DPM for payments. We had a to do a lot of custom programming for this client as they needed sales tax, promo codes, and different shipping rates for different zip codes. 

 

I was delighted throughout the whole process with how much I was able to tailor the editing experience for the client as well as the visitor's experience on the page. The client had several last minute requirements which we would never have been able to implement in the time we had if we were using a different CMS and didn't have PW's API and custom field system.

 

I would like at some point to release some of the new shopping cart code (shipping rates by zip code, sales tax, promo codes) to the rest of the community, but as it stands it's not modularized/generic enough and the code is in too many different pieces to make it practical. If I have time outside of work I will try to see if I can make it more distributable so that I can give back something to PW :)

 

Special thanks to Apeisa for his input when we were getting started with this.

 

http://www.harkenslandscapesupply.com/


Illegal offset error when trying to edit page through API

14 March 2013 - 11:04 AM

I am trying to edit a page through the API. I can echo fields from the page and I can perform the save() function, but if I try to make changes to the page first, it gives me a bunch of illegal offset errors like this:

 

Warning: Illegal offset type in isset or empty in /opt/disk1/www/mywebsite.com/wire/core/Data.php on line 41

 

Here is my code:

 

    $my_page = $pages->get($my_page_id);


    $my_page->setOutputFormatting(false);
    $my_page->time_field = time();
    $my_page->removeStatus(Page::statusUnpublished);
    echo "page title: " . $order->title ."\n"; // this works
    $my_page->save(); // fails
 

 

 
Any ideas? Thanks in advance.

Image reuse outside of TinyMCE

08 March 2013 - 06:47 PM

Hi guys-

 

I'm building a site which has large background images, some of which will be consistent across pages and some which will vary with each page. I would like to be able to allow the client to select the background image for each page.

 

Since these are very large images, I don't want to just provide a standard image field, since this will mean the same image will get uploaded to multiple places/pages. Since I'm trying to provide a good user experience for the end user, I don't want their browser using up bandwidth downloading the same image multiple times.

 

What is a good way to do this? I know that with TinyMCE you can select an image stored on another page, but is there some way to do this without a TinyMCE field? I'm thinking of setting up a page as a central repository of shared images and then providing some way to select between those on each individual page, but I don't know how/if this is possible.

 

Thanks in advance! 


Finding the value of one field on a page where another field contains a specified string

15 February 2013 - 08:45 PM

Hi guys,

I asked a similar question to this a little while back, but this time it's a bit different (and hopefully better worded).

 

I have a page with a repeater on it containing 2 fields. Using the API, I want to find the value of field 1 where field 2 contains a certain specified string. What is the best way of doing this?

 

I suppose this is the same as asking how to find the value of one field on a page given the value of another field on that page, since PW handles repeating fields as pages under the hood.

 

Any help is much appreciated.