我试图看看我是否可以找到一种方法在Squarespace上使用CUSTOM CSS或HTML作为我网站的徽标。最大像素数为320,我的徽标仍然很小。我试图通过编码来找到解决方法。我是编写自定义CSS和HTML的新手,并且想要了解如何以更大的像素数量在每个页面上居中我的徽标。通过使用图像块可能只是使我的徽标居中。
答案 0 :(得分:2)
我检查了您的网页,发现了您的问题。
<?php
$total_amount=8123.52;
$number = $total_amount;
$no = round($number);
$point = round($number - $no, 2) * 100;
$hundred = null;
$digits_1 = strlen($no);
$i = 0;
$str = array();
$words = array('0' => '', '1' => 'one', '2' => 'two',
'3' => 'three', '4' => 'four', '5' => 'five', '6' => 'six',
'7' => 'seven', '8' => 'eight', '9' => 'nine',
'10' => 'ten', '11' => 'eleven', '12' => 'twelve',
'13' => 'thirteen', '14' => 'fourteen',
'15' => 'fifteen', '16' => 'sixteen', '17' => 'seventeen',
'18' => 'eighteen', '19' =>'nineteen', '20' => 'twenty',
'30' => 'thirty', '40' => 'forty', '50' => 'fifty',
'60' => 'sixty', '70' => 'seventy',
'80' => 'eighty', '90' => 'ninety');
$digits = array('', 'hundred', 'thousand', 'lakh', 'crore');
while ($i < $digits_1) {
$divider = ($i == 2) ? 10 : 100;
$number = floor($no % $divider);
$no = floor($no / $divider);
$i += ($divider == 10) ? 1 : 2;
if ($number) {
$plural = (($counter = count($str)) && $number > 9) ? 's' : null;
$hundred = ($counter == 1 && $str[0]) ? ' and ' : null;
$str [] = ($number < 21) ? $words[$number] .
" " . $digits[$counter] . $plural . " " . $hundred
:
$words[floor($number / 10) * 10]
. " " . $words[$number % 10] . " "
. $digits[$counter] . $plural . " " . $hundred;
} else $str[] = null;
}
$str = array_reverse($str);
$result = implode('', $str);
$points = ($point) ?
"." . $words[$point / 10] . " " .
$words[$point = $point / 10] : '';
echo $result . "(Approx)" ;
?>
.Header-branding-logo
max-width: 320px;
使你的每一个尺寸都没用,因为最大宽度只有320px,根据你不够大。
所以,我删除了它并修改了代码如下
.Header-branding-logo {
width: 200%;
position: relative;
left: -50%;
}
现在,徽标的宽度是容器top-center
宽度的两倍。 position:relative; left:-50%;
用于定位您的徽标。