Switching 'Site nam'e Logo for phones

Permalink Browser Info Environment
Chris,

Is there a way to serve up an alternative (smaller) logo image when browsing on phones?

My current logo pushes the nav button for phones, onto the next line. which increases the nav header depth.

Cheers

Nigel

Type: Discussion
Status: In Progress
darkmatter
View Replies:
c5mix replied on at Permalink Reply
c5mix
Try adding this CSS to the Add your CSS box in the theme's customization panel:
@media (max-width: 767px) {
#logo { max-width:200px; }
}

This will put a max-width on the logo when in phone view. Change the 200px to whatever works for you.
darkmatter replied on at Permalink Reply
darkmatter
works great ..thanks!
c5mix replied on at Permalink Reply
c5mix
You're welcome!
darkmatter replied on at Permalink Reply
darkmatter
works great ..thanks!
scrivener replied on at Permalink Reply
scrivener
I have a related problem with the Site Name--it wraps around on mobile phones and overlaps the photo. Looks okay when the phone is horizontal, but not when vertical. Any simple fix?

And related to that related problem: I moved the revolving text feature down the page on one site using some CSS you had given me for a different site (where I wanted to move the feature _up_) that uses a fixed number of pixels displacement. The one that's higher I can get away with on the mobile site, but the lower one pushes the feature way too far down the page. Is there a proportional measure I can use to position that feature so that it will render properly on the mobile devices?

Many thanks,
A
c5mix replied on at Permalink Reply
c5mix
For Site Name you can try decreasing the font size by adding this in the Add your CSS box in the theme's customization panel:
@media (max-width: 767px) {
#nav .navbar-brand, #nav .navbar-brand h1 {
font-size: 20px;
}
}

Adjust accordingly. Or you can change it to an image and use the code I originally pasted above.
scrivener replied on at Permalink Reply
scrivener
20px looks great, thanks!
scrivener replied on at Permalink Reply
scrivener
Related(?) issue: The main home picture looks great in the landscape phone view, scales beautifully, but gets about 40% of the right side cut off in the portrait view. Those are some wide pics; is there an easy fix for the portrait view? (NB - It doesn't matter to me if the pic shrinks to a pretty small size overall to get all that width into the relatively narrow portrait view.)
c5mix replied on at Permalink Reply
c5mix
It's because the CSS for the #feature div is set to have the background image "cover" or fit-in the whole area. Take a look at this thread:
http://www.concrete5.org/marketplace/themes/treviso/support/jumbotr...
scrivener replied on at Permalink Reply
scrivener
Hey, Chris. New wrinkle.

I have a family of three sites (three dealerships, one company) that are using the Treviso theme. The first two were handled with the CSS above reducing the text size to 20px. On the third I was asked to add a gif of a rotating windmill as their logo, then the company name. To make the height of everything work I set the text of the company name to 46px in the Site Name stack, but now the CSS patch you gave above is not working on this site. I tried adding !important to the text size with no change.

I'm wondering if there's a way to just suppress the gif altogether on the mobile site (because the alternative would be to shrink it to a size that won't look good). (I'm not sure it looks good now, but the client loves it.) Is that an easy fix or a big problem?

Many thanks,
Andrew
c5mix replied on at Permalink Reply
c5mix
Yeah if you add a unique ID to the gif image you can then "display:none" it when on mobile.
c5mix replied on at Permalink Reply
c5mix
Regarding the other issue can you post a link to the page so I can take a look and see what you mean?
scrivener replied on at Permalink Reply
scrivener
Site where moving the feature up works more or less on mobile phone view: reliablehomesofsealy.com

Site where moving the feature down doesn't work so hot on mobile phone view: huntsvillereliablehomes.com
c5mix replied on at Permalink Reply
c5mix
Just apply some different CSS that moves it up/down if you're on a mobile phone. You can target it like in the code above using
@media (max-width: 767px) {
}

concrete5 Environment Information

# concrete5 Version
5.6.3.3

# concrete5 Packages
Deluxe Image Gallery (1.6.6), FlexSlider (2.2.0.5), Lightboxed Image (0.9.2), Mosaic Gallery (1.2.3), Nivo Slider (2.0.1), Pro News (5.1.0), Treviso Theme (0.9.9), Whale Nivo Image Slider (1.2).

# concrete5 Overrides
languages/el_GR, languages/pt_PT, languages/sk_SK, languages/ro_RO, languages/da_DK, languages/sv_SE, languages/es_MX, languages/ar, languages/it_IT, languages/fr_FR, languages/es_ES, languages/nb_NO, languages/zh_TW, languages/es_PE, languages/nl_NL, languages/de_DE, languages/ja_JP, languages/vi_VN, languages/tr_TR, languages/es_AR, languages/sl_SI, languages/fi_FI, languages/cs_CZ, languages/ru_RU, languages/fa_IR, themes/treviso_custom

# concrete5 Cache Settings
Block Cache - Off
Overrides Cache - Off
Full Page Caching - Off

# Server Software
Apache/2.2.22 (Linux/SUSE)

# Server API
apache2handler

# PHP Version
5.3.15

# PHP Extensions
apache2handler, bcmath, bz2, calendar, Core, ctype, curl, date, dom, ereg, exif, filter, ftp, gd, gettext, gmp, hash, iconv, imap, json, ldap, libxml, mbstring, mcrypt, mhash, mysql, mysqli, mysqlnd, odbc, openssl, pcntl, pcre, PDO, pdo_mysql, PDO_ODBC, pdo_pgsql, pdo_sqlite, pgsql, posix, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, SQLite, sqlite3, standard, sysvmsg, sysvsem, sysvshm, tokenizer, wddx, xml, xmlreader, xmlrpc, xmlwriter, xsl, zip, zlib.

# PHP Settings
max_execution_time - 30
log_errors_max_len - 1024
max_file_uploads - 20
max_input_nesting_level - 64
max_input_time - 60
max_input_vars - 1000
memory_limit - 128M
post_max_size - 8M
safe_mode - Off
safe_mode_exec_dir - <i>no value</i>
safe_mode_gid - Off
safe_mode_include_dir - <i>no value</i>
sql.safe_mode - Off
upload_max_filesize - 2M
ldap.max_links - Unlimited
mysql.max_links - Unlimited
mysql.max_persistent - Unlimited
mysqli.max_links - Unlimited
mysqli.max_persistent - Unlimited
odbc.max_links - Unlimited
odbc.max_persistent - Unlimited
pcre.backtrack_limit - 1000000
pcre.recursion_limit - 100000
pgsql.max_links - Unlimited
pgsql.max_persistent - Unlimited
session.cache_limiter - nocache
session.gc_maxlifetime - 7200
soap.wsdl_cache_limit - 5
safe_mode_allowed_env_vars - PHP_
safe_mode_protected_env_vars - LD_LIBRARY_PATH

Browser User-Agent String

Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.90 Safari/537.36

Hide Post Content

This will replace the post content with the message: "Content has been removed by an Administrator"

Hide Content

Request Refund

You may not request a refund that is not currently owned by you.