Phillip D.
Forum Replies Created
Viewing 4 replies - 1 through 4 (of 4 total)
-
Forum: Plugins
In reply to: [Airpress] Creating records in Airpress via APIUpon further review, the following seems to be the intended way to add records (that uses the AirpressConnect::create() method from above). The benefit of this method is you actually get a record object of the newly created record.
$record_data = array( 'Some Column' => 'Your data', 'Another Column' => 'More data', ); $query = new AirpressQuery( 'YOURTABLE', 'YOURCONFIG' ); $collection = new AirpressCollection( $query, false ); $new_record = $collection->createRecord( $record_data );Forum: Plugins
In reply to: [Airpress] Creating records in Airpress via APIAfter digging around the source files, I found this static method that creates records:
$air_data = array( 'Some Column' => 'Your data', 'Another Column' => 'More data', ); AirpressConnect::create( 'YOURCONFIG', 'YOURTABLE', $air_data );- This reply was modified 7 years, 1 month ago by Phillip D..
Forum: Plugins
In reply to: [Price Based on Country for WooCommerce] Add currency to priceI added CAD to the Canadian Dollar (CAD$) by hooking into the
woocommerce_currency_symbolfilter.In
functions.php, I put:add_filter('woocommerce_currency_symbol', 'prepend_canadian_currency_symbol', 10, 2); function prepend_canadian_currency_symbol($symbol, $currency) { return $currency == 'CAD' ? $currency . $symbol : $symbol; }I ran into this issue yesterday. My issue was that I was trying to publish an event without a location but I didn’t check the “This event does not have a physical location.” checkbox.
Viewing 4 replies - 1 through 4 (of 4 total)