estateagent content element

  • nuri
  • Autore della discussione
  • Offline
  • Nuovo Utente
  • Nuovo Utente
Di più
13 Anni 6 Giorni fa #256 da nuri
estateagent content element è stato creato da nuri
hi i am just trying a create new contentelement for estate agent improved
Code:
<content_table required="1"> <table name="table" required="1">estateagent</table> <field name="label" type="text" required="1">estateagent</field> <field name="id" type="fieldname" required="1">id</field> <field name="obj_id" type="fieldname" required="1">obj_id</field> <field name="title" type="fieldname" required="1">title</field> <field name="title_alias" type="fieldname" required="0">alias</field> <field name="sectionid" type="fieldname" required="0"></field> <field name="catid" type="fieldname" required="0">cat</field> <field name="created" type="fieldname" required="0">date</field> <field name="description" type="fieldname" required="1">description</field> <!--<field name="description" type="fieldname" required="1">url</field>--> <!--<field name="fulltext" type="fieldname" required="0">description</field>--> <field name="state" type="fieldname" required="1">published</field> <field name="access" type="fieldname" required="0"></field> <field name="publish_up" type="fieldname" required="0"></field> <field name="publish_down" type="fieldname" required="0"></field> <!-- if images is set, images_dir is required --> <field name="images" type="fieldname" required="0"></field> <field name="images_dir" type="text" required="0"></field> <field name="ordering" type="fieldname" required="0"></field> <!-- following pars are ues to put together the url to open the detail view of the content item e.g. option=com_content&task=view&id=<replaced with id> Joomla 1.5 supports the view model, so it is avisable tu use 'href_view' instead of href_task - slug links generates links as id:title-alias --> <field name="href_option" type="text" required="1">com_estateagent</field> <field name="href_task" type="text" required="0"></field> <field name="href_view" type="text" required="1">estateagent</field> <field name="href_id" type="text" required="1">id</field> <field name="slug_links" type="text" required="0">1</field> <field name="href_catid" type="text" required="0">catid</field> </content_table> <!-- required fields of category table , are required only if category table exists --> <category required="0"> <table name="table" required="1">estateagent_categories</table> <field name="cat_table_id" type="fieldname" required="1">id</field> <field name="cat_table_title" type="fieldname" required="1">name</field> <field name="cat_table_alias" type="fieldname" required="0">alias</field> <field name="cat_table_published" type="fieldname" required="0">published</field> <field name="cat_table_ordering" type="fieldname" required="0">ordering</field> <!-- Link to a section table. It can be a combination of a table and a field, or a string to filter the category id with --> <field name="cat_parent_section_table" type="table" required="0"></field> <field name="cat_parent_section_field" type="fieldname" required="0">section</field> <field name="cat_section_filter" type="text" required="0">com_estateagent</field> </category> <!-- required fields of section table , are required only if section table exists --> <section required="0"> <table name="table" required="1"></table> <field name="sec_table_id" type="fieldname" required="1"></field> <field name="sec_table_title" type="fieldname" required="1"></field> <field name="sec_table_alias" type="fieldname" required="0"></field> <field name="sec_table_published" type="fieldname" required="0"></field> <field name="sec_table_ordering" type="fieldname" required="0"></field> </section>

i can select properties and i can add tags to each property but in page i have that error
Warning: Invalid argument supplied for foreach() in /home/xxxxxxx/public_html/administrator/components/com_customproperties/views/assign/view.html.php on line 169
and cant show on page!!

so i do some mistakes but where :) ??

Si prega Accesso o Crea un account a partecipare alla conversazione.

Di più
13 Anni 5 Giorni fa #257 da andrea_4g
Risposta da andrea_4g al topic Re: estateagent content element
The content element you wrote looks good. I guess the problem could be possibly caused by a wrong field name that causes the SQL query to fail.

That's how we troubleshoot new content element connectors:
1) have CP print the query: uncomment line 900 in components/com_customproperties/models/search.php (yes, it's that strange line...)
2) run a CP search
3) grab the SQL statement from the screen, replace #_ with jos, and run it on a local copy of the Joomla DB; at this point we usually get an error that tells us what we did wrong and what to change.
4) make modification and reinstall the content element
5) repeat until it works

Si prega Accesso o Crea un account a partecipare alla conversazione.

Tempo creazione pagina: 0.118 secondi