Posts

Featured post

magento - SQLSTATE[42S22]: Column not found: 1054 Unknown column 'SUM((IFNULL(main_table.base_total_invoiced, 0) -

i on magento 1.9.1 , worked fine. wanted uppgrade zend framework 1.12.7 1.12.13. after uppdating got error message when logging in backend. -- sqlstate[42s22]: column not found: 1054 unknown column 'sum((ifnull(main_table.base_total_invoiced, 0) - ifnull(main_table.base_tax_invoiced, 0) - ifnull(main_table.base_shipping_invoiced, 0) - (ifnull(main_table.base_total_refunded, 0) - ifnull(ma' in 'field list', query was: select `sum((ifnull(main_table.base_total_invoiced, 0) - ifnull(main_table.base_tax_invoiced, 0) - ifnull(main_table.base_shipping_invoiced, 0) - (ifnull(main_table.base_total_refunded, 0) - ifnull(main_table.base_tax_refunded, 0) - ifnull(main_table.base_shipping_refunded, 0))) * main_table`.`base_to_global_rate)` `lifetime`, `avg((ifnull(main_table.base_total_invoiced, 0) - ifnull(main_table.base_tax_invoiced, 0) - ifnull(main_table.base_shipping_invoiced, 0) - (ifnull(main_table.base_total_refunded, 0) - ifnull(main_table.base_tax_refunded, 0) ...

ajax - Javascript trim whitespace on click -

i have email form field. on click, executes javascript ... $(document).on('click', '#add_delegate', function() { registrationhelper.added_delegate = true; // var button = $(event.target); var button = $(this); var uri = button.data('url'); if (typeof uri === 'undefined') { return false; } var input = $('#email_search'); var data = {email:input.val()}; data.text().replace(/ /g,''); var spinner = $('#delegate_add_spinner'); spinner.css({display:'inline-block'}); $.ajax({type:'post', url: uri, data:data}).success(function(card) { var html = $(card); var data_id = html.attr('data-id'); var existing_elem = $('.mini_addresscard[data-id=' + data_id + ']'); if (existing_elem.length < 1) { input.popover('hide'); // in seperate timeout because ie8 damn stupid; crashes if run directly settimeout(function () { $(...

Font missing with Crystal Reports generated PDF -

Image
i have crystal report 8.5 file, need export pdf. that report contains field need represent bar code. achieve use truetype font. if open generated pdf file on machine see bar code. but if open machine doesn't have font installed, see numbers. how can assure codebar visible on pdf if computer doesn't have font installed? if not want include font, can generate image , call via http. the barcode below generated using online barcode generator courtesy of wasp: http://www.waspbarcode.com/services/waspbarcode/barcodegen.ashx?symbology=code128&code=font_missing_31301980 steps report: create blank jpg using ms paint. resize without aspect ratio checked on. insert image placer holder such 50x323 png crystal report right-click on graphic , select format graphic... click on picture tab, click on formula, enter formula create formula url above. want retrieve barcode data database , concatenate prefix , barcode field together: "http://...

python - Flask and Jinja for loop skip if file contains errors -

i'm having issue trying display thumbs. problem when run jinja2 variable displays alt text, rather have skip or pass if thumb contains errors instead of displaying alt text. here code {% block content %} {% if games %} {% g in games if g.game_thumb %} <img src="static{{ g.game_thumb }}" class="img-rounded" alt="{{ g.game_name }}" width="150" height="150"> {%endfor%} {% endif %} {% endblock %} i ended solving via flask route via. from pil import image try: image.open(thumb).verify() print "image" except: print "failed" continue

Using PHP to Create XML; Accessing via Flash -

i working on project need continuously create , update xml file. feasible way php; can't use filereference in flash because save as; cannot use filestream because i'm using flash player, not air; don't want use sharedobject because need user able access data in xml multiple computers. basically, whenever user clicks on something, flash grabs color of object. need put color, each time clicked, xml file (there 1 file; stores of colors, , continuously updated). reason needs continuously updated because there no save button; once user exits page, they're done. need progress saved. is there way generate xml using php/flash? understand how generate xml file in php, i'm unsure on how update using flash (which uses php). the main idea have right use loader in as3 php file, grab php file's data, xml file. once load php file in flash, can modify xml file using flash? if not, how modify using flash php? sorry if confusing; spent hours creating couple different ...

module - How can I use import, from import and sys.append together in Python -

i have directory add sys.path import custom modules. correct/best way use import, import , sys.path together? mean if acceptable use sys.path.append in between "imports". for example: #!c:/python27 import sys sys.path.append('c:\\users\\user\\mypythonmodules') import writedata wd import os import csv collections import defaultdict edit: i should have mentioned writedata custom module want import wd . module writedata located in c:\\users\\user\\mypythonmodules yes, is. there no syntax or semantic rule in language prevents that. i not aware of "style" rule may breaking, in case, option providing pythonpath python interpreter.

asp.net mvc - Cannot display error message on Editor or EditorFor -

in mvc application, can display error messages inputs i.e. textboxfor , dropdownlist , etc. however, using same approach, cannot show validation error kendo().editor() or kendo().editorfor() . tried validationmessage beside validationmessagefor , not make sense. might problem be? view: <script type="text/javascript"> $(function () { //for using kendo validation: $("form").kendovalidator(); }); </script> //validation works textboxfor, dropdownlist, etc.: @html.labelfor(m => m.summary) @html.textboxfor(m => m.summary, new { maxlength = 50, @class = "k-textbox"}) @html.validationmessagefor(m => m.summary) //validation not work editor or editorfor: @html.labelfor(m => m.description, new { maxlength = 1000, @class = "editor-label" }) @(html.kendo().editor() //@(html.kendo().editorfor(m=>m.description) //also tried .name("description") .htmlattributes(new { @class...