Closed (fixed)
Project:
SimpleAds
Version:
7.x-1.x-dev
Component:
Documentation
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
21 Jan 2012 at 10:40 UTC
Updated:
11 Dec 2012 at 08:10 UTC
I created a simpleads block view, with the simpleads style plugin, title and image ad fields, and a taxonomy ad group filter. In the preview I cannot see nothing, but when I go to the front page (where I added the block), I got the following errors, and I cannot see the ads, just the title of the block (I can confirm that I have 2 ads in the filtered group):
Notice: Undefined property: views_plugin_query_default::$limit en template_preprocess_views_simpleads() (línea 52 de /var/aegir/platforms/commerce/sites/example.com/modules/simpleads/includes/simpleads.integration.inc).
Notice: Undefined variable: tid en template_preprocess_views_simpleads() (línea 64 de /var/aegir/platforms/commerce/sites/example.com/modules/simpleads/includes/simpleads.integration.inc).
Notice: Undefined variable: tid en template_preprocess_views_simpleads() (línea 73 de /var/aegir/platforms/commerce/sites/example.com/modules/simpleads/includes/simpleads.integration.inc).
Notice: Undefined variable: tid en template_preprocess_views_simpleads() (línea 75 de /var/aegir/platforms/commerce/sites/example.com/modules/simpleads/includes/simpleads.integration.inc).
Warning: array_merge(): Argument #1 is not an array en _simpleads_render_ajax_template() (línea 154 de /var/aegir/platforms/commerce/sites/example.com/modules/simpleads/includes/simpleads.helper.inc).
Any idea about waht is happening?
Comments
Comment #1
minnur commentedPlease try to enable default example SimpleAds View and see if that works. If it does, just clone it.
Please note that the sample View has minimum required configuration (e.g Fields etc..).
Comment #2
akalam commentedI got it!
Now I understand that, in order to get views support, you cannot use any fields but the "Content: Ad Group" field. Its true that the README suggest to enable the example view and then you can understand this point, but I think that it still not very clear. May be it could be a little bit more documentated?
Also, to get all the strong about views, is important to could configure how the fields are displaying, and Ad Group field is like a node list itself, not exactly a field, and you cannot configure, for example, image-styles for specifc blocks or views, but this is another stuff. Should I create another issue for that?
I also have to tell that I'm very positively suprised about this module, becouse it is filling the empty that the ads module created in our drupal 7 hearts. Thank you very much, also about the fast support!
Comment #3
sachinbal commentedHi,
I have a query on SimpleAds and I was not getting the right forum to post my query and hence posting this here. I have installed the SimpleAds module and I can see it under the "content types" but I am not able to add it to a block. Can someone please guide me on the same?
Thanks
Sachin
Comment #4
minnur commented@sachinbal , it should be on Structure -> Blocks page. If you would like to add a new block, simply create a new taxonomy term in Ad Group vocabulary.
Comment #5
billsdesk commentedWhen I edited the SimpleAds View example in Views, I got a message about field errors. The only solution was to create one field for a text ad, which I am trying to create. However, every time I save a view, I get the following error message:
Notice: Trying to get property of non-object in _simpleads_node_stat_tab() (line 174 of sites/all/modules/simpleads/includes/simpleads.helper.inc).
I also discovered that the machine name was block_1. I was receiving warning errors every time I loaded a page about simpleads_block not found. I changed the machine name to simpleads_block, and the error went away. Am I missing something?
Comment #6
minnur commentedI am not sure. I will check this soon. Thanks.
Comment #7
minnur commentedComment #9
bpriceless commentedChanging the Pager settings from "display all" to "display a specific number of items" works around the "undefined property" notice/error.
Comment #10
rajasekar33 commentedwhen your Changing the Pager settings "display all"
getting Notice error: Notice: Undefined property: views_plugin_query_default::$limit in template_preprocess_views_simpleads() (line 148 of /.../sites/all/modules/simpleads/includes/simpleads.theme.inc).
Suggest to replace line 148
//the problem is happen for ads_list limit. when setting "display all" delta_limit->all
- $limit = check_plain($view->query->limit);
+ $limit = (isset($view->query->limit))?check_plain($view->query->limit):count($rows);
Comment #11
minnur commentedDev version already has the following code: