Null values resetting themselves in Theme Settings input fields and some documentation notess

lapinpub's picture
lapinpub
Wed, 05/27/2015 - 23:33
#1
Null values resetting themselves in Theme Settings input fields and some documentation notess

1) Working on the "contact-info" block on the map section yesterday I was wanting to remove "fax" from the block and was able to do so by clearing the text in the field.  However, at some point working around on the system the field would mysteriously repopulate itself with no rhyme or reason.  Digging deeper today I was adding another fiield to the block (in PHP) and found a pretty major bug in the code (and the answer to my problem from the previous day.

If you look in template\views\contact\views-view-contact-block.tpl.phpviews-view-content-block.tpl.php (line 38) you'll see that on display of the edit field the value is being pulled from the theme database.  However, in inc\theme-settings-display.inc under 'form['md_boom_settings']['display']['contact']['detail']['fax']['#default_value']' (line 78) which populates the edit form the input value is being set with the code $fax ? $fax : t('+84 012 345 6789') which causes the form to clobber any emptied fields each time the page is re-populated.  

Inclusion of constants in code is never a good idea and this is a good example why.  The following is more proper, fixes the problem and still works just as well: $fax ? $fax : t('').  It would be a good idea to remove all of these constants from this file (and related ones) in the next service release for your template.

2) On the overview page I was wanting to update the overview object to remove the first tab but the documenation is empty under the "Adding Overview" section.  Is there other documentation elsewhere?  I was able to locate the origanal manual for the MD Slider which was very helpful for updating that.  (http://www.killeenstudio.com/sites/all/modules/md_slider/Documentation/#...)

3) In the documentation under "Services" it states that services are identical to blog entires which is not quite accurate.  They contain a fontello icon which is displayed as a spinner when the item is pointed to in the browser which is selected from a drop-down on the content-edit page.  I was able to find a list of the icons at https://www.drupal.org/project/fontello.  It might be nice to reference that in the documentation (I'm pretty new to drupal and had to go through the code to figure it out.

4) In the documentation you mention that there are about 20 block regions however I was looking for one that simply had title/subtitle/text and nothing else to create a simple "page" view (basically to replace the "about us" widgit with a simple mission statement.  I was not able to find a simple way to do that... am I missing something? 

Again, I'm pretty new to Drupal so apologies if I overstep... your theme is excellent and my client is very excited about what we've produced so far.

phuonght's picture
phuonght
Thu, 05/28/2015 - 00:18

Hi,

Thank you for your detailed feedbacks. They will help us a lot to impove our product's quality. 

And about blocks, if you want a simple block with only title, subtile and text, you can try to add new block in admin/structure/block/add

phuonght's picture
phuonght
Fri, 05/29/2015 - 00:28

So you would like to know how to edit your "Our mission" section in following image? 

https://www.dropbox.com/s/c7yoem6uc7tsm2x/OverviewBlock.png?dl=0

Exactly how do you want it become? 

Please describe in detail. We can guide you the way to do.

Log in or register to post comments
Have More Idea?

We are here to build your website!

No Universal solution fits all special business requirements. Our experienced team is ready with ideas and state-of-the-art technical solutions to consult the best solution within your budget.