Jump to content

[SOLVED] SVG - Firefox/Konqueror failing, Opera doing just fine


Recommended Posts

Now I know the time isn't quite ripe for SVG's yet as internet explorer doesn't support them at all and support in other browsers is quite poor, but I got a svg which if accessed directly is rendering just fine in both konqueror and firefox.. but when used on a page it shows up as a dead link.

Opera is rendering it just fine both on the page and on direct access.

 

The page is valid xhtml 1.0 and the following code is used to include it.

<img src='images/folder.svg' alt='' />

 

If anyone has an idea on what is going wrong, please do tell :)

 

The svg itself (which I suspect is the culprit by using some unsupported feature.. but on direct access it shows up fine, so I'm puzzled):

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
   xmlns:svg="http://www.w3.org/2000/svg"
   xmlns="http://www.w3.org/2000/svg"
   xmlns:xlink="http://www.w3.org/1999/xlink"
   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
   version="1.0"
   width="317.2186"
   height="317.2186"
   id="svg11823">
  <defs
     id="defs11825">
    <filter
       id="filter3530">
      <feGaussianBlur
         id="feGaussianBlur3532"
         stdDeviation="1.0172855"
         inkscape:collect="always" />
    </filter>
    <linearGradient
       id="linearGradient3534">
      <stop
         id="stop3536"
         style="stop-color:#ffffff;stop-opacity:1"
         offset="0" />
      <stop
         id="stop3538"
         style="stop-color:#ffffff;stop-opacity:0"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="81.348701"
       y1="55.91547"
       x2="114.70522"
       y2="140.30176"
       id="linearGradient3540"
       xlink:href="#linearGradient3534"
       gradientUnits="userSpaceOnUse"
       gradientTransform="translate(-549.10198,-163.20059)" />
    <filter
       id="filter3500">
      <feGaussianBlur
         id="feGaussianBlur3502"
         stdDeviation="1.0208063"
         inkscape:collect="always" />
    </filter>
    <linearGradient
       id="linearGradient3488">
      <stop
         id="stop3490"
         style="stop-color:#000000;stop-opacity:1"
         offset="0" />
      <stop
         id="stop3492"
         style="stop-color:#000000;stop-opacity:0"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="75.485207"
       y1="216.26877"
       x2="150.18037"
       y2="78.337875"
       id="linearGradient3494"
       xlink:href="#linearGradient3488"
       gradientUnits="userSpaceOnUse"
       gradientTransform="translate(-549.10198,-163.20059)" />
    <linearGradient
       id="linearGradient3428">
      <stop
         id="stop3430"
         style="stop-color:#ffffff;stop-opacity:1"
         offset="0" />
      <stop
         id="stop3432"
         style="stop-color:#ffffff;stop-opacity:0"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="150.07268"
       y1="69.702202"
       x2="153.63531"
       y2="103.83543"
       id="linearGradient3737"
       xlink:href="#linearGradient3428"
       gradientUnits="userSpaceOnUse"
       gradientTransform="translate(-549.10198,-163.20059)" />
    <linearGradient
       id="linearGradient3413">
      <stop
         id="stop3415"
         style="stop-color:#000000;stop-opacity:1"
         offset="0" />
      <stop
         id="stop3417"
         style="stop-color:#000000;stop-opacity:0"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="-75.3908"
       y1="321.58548"
       x2="127.22198"
       y2="102.69514"
       id="linearGradient3419"
       xlink:href="#linearGradient3413"
       gradientUnits="userSpaceOnUse"
       gradientTransform="translate(-549.10198,-163.20059)" />
    <linearGradient
       id="linearGradient3468">
      <stop
         id="stop3470"
         style="stop-color:#d8d8d8;stop-opacity:1"
         offset="0" />
      <stop
         id="stop3476"
         style="stop-color:#f0f0f0;stop-opacity:1"
         offset="0.22455101" />
      <stop
         id="stop3478"
         style="stop-color:#ffffff;stop-opacity:1"
         offset="0.46812087" />
      <stop
         id="stop3480"
         style="stop-color:#f3f3f3;stop-opacity:1"
         offset="0.76308393" />
      <stop
         id="stop3472"
         style="stop-color:#d6d6d6;stop-opacity:1"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="198.59323"
       y1="97.137428"
       x2="58.94891"
       y2="147.25517"
       id="linearGradient3474"
       xlink:href="#linearGradient3468"
       gradientUnits="userSpaceOnUse"
       gradientTransform="translate(-549.10198,-163.20059)" />
    <linearGradient
       x1="-4.7339954"
       y1="184.17795"
       x2="227.46077"
       y2="56.955963"
       id="linearGradient3328"
       xlink:href="#linearGradient3314"
       gradientUnits="userSpaceOnUse"
       gradientTransform="translate(-549.10198,-163.20059)" />
    <linearGradient
       id="linearGradient2407">
      <stop
         id="stop2409"
         style="stop-color:#003a93;stop-opacity:0.79865772"
         offset="0" />
      <stop
         id="stop2411"
         style="stop-color:#7db1ff;stop-opacity:0.71812081"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="664.31964"
       y1="393.5126"
       x2="255.13704"
       y2="778.66467"
       id="linearGradient2533"
       xlink:href="#linearGradient2407"
       gradientUnits="userSpaceOnUse"
       gradientTransform="matrix(0.3145759,3.3099795e-2,-3.1702795e-2,0.284888,-530.57037,-223.10227)" />
    <linearGradient
       id="linearGradient3548">
      <stop
         id="stop3550"
         style="stop-color:#ffffff;stop-opacity:1"
         offset="0" />
      <stop
         id="stop3552"
         style="stop-color:#ffffff;stop-opacity:0"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="78.742409"
       y1="77.995888"
       x2="26.839462"
       y2="35.082928"
       id="linearGradient3554"
       xlink:href="#linearGradient3548"
       gradientUnits="userSpaceOnUse"
       gradientTransform="translate(-529.08226,-219.5891)" />
    <filter
       height="1.3535888"
       y="-0.17679441"
       width="1.0257477"
       x="-0.012873816"
       id="filter3342">
      <feGaussianBlur
         id="feGaussianBlur3344"
         stdDeviation="0.73981434"
         inkscape:collect="always" />
    </filter>
    <linearGradient
       id="linearGradient3354">
      <stop
         id="stop3356"
         style="stop-color:#ffffff;stop-opacity:1"
         offset="0" />
      <stop
         id="stop3358"
         style="stop-color:#ffffff;stop-opacity:0"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="122.18343"
       y1="38.274925"
       x2="50.208416"
       y2="94.389671"
       id="linearGradient3360"
       xlink:href="#linearGradient3354"
       gradientUnits="userSpaceOnUse"
       gradientTransform="translate(-549.10198,-163.20059)" />
    <filter
       height="1.04241"
       y="-0.021204988"
       width="1.2381849"
       x="-0.11909245"
       id="filter3384">
      <feGaussianBlur
         id="feGaussianBlur3386"
         stdDeviation="0.81591018"
         inkscape:collect="always" />
    </filter>
    <linearGradient
       id="linearGradient3368">
      <stop
         id="stop3370"
         style="stop-color:#000000;stop-opacity:1"
         offset="0" />
      <stop
         id="stop3372"
         style="stop-color:#000000;stop-opacity:0"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="-52.615292"
       y1="111.33359"
       x2="-89.16851"
       y2="-160.22696"
       id="linearGradient3374"
       xlink:href="#linearGradient3368"
       gradientUnits="userSpaceOnUse"
       gradientTransform="matrix(1.0010993,0,0,0.9771436,-428.22672,-61.489698)" />
    <linearGradient
       id="linearGradient3445">
      <stop
         id="stop3447"
         style="stop-color:#ffffff;stop-opacity:1"
         offset="0" />
      <stop
         id="stop3449"
         style="stop-color:#ffffff;stop-opacity:0"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="79.24601"
       y1="-126.40256"
       x2="140.07268"
       y2="166.59012"
       id="linearGradient3451"
       xlink:href="#linearGradient3445"
       gradientUnits="userSpaceOnUse"
       gradientTransform="matrix(1,0,0,0.6634183,-549.10198,-146.13056)" />
    <linearGradient
       id="linearGradient3314">
      <stop
         id="stop3316"
         style="stop-color:#283f8a;stop-opacity:1"
         offset="0" />
      <stop
         id="stop3318"
         style="stop-color:#0089e9;stop-opacity:1"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="46.210991"
       y1="40.43428"
       x2="115.25708"
       y2="167.01372"
       id="linearGradient3320"
       xlink:href="#linearGradient3314"
       gradientUnits="userSpaceOnUse"
       gradientTransform="translate(-549.10198,-163.20059)" />
    <linearGradient
       id="linearGradient2395">
      <stop
         id="stop2397"
         style="stop-color:#5599ff;stop-opacity:1"
         offset="0" />
      <stop
         id="stop2399"
         style="stop-color:#c2dbff;stop-opacity:1"
         offset="1" />
    </linearGradient>
    <linearGradient
       x1="218.05919"
       y1="352.40601"
       x2="274.42526"
       y2="77.315956"
       id="linearGradient2536"
       xlink:href="#linearGradient2395"
       gradientUnits="userSpaceOnUse"
       gradientTransform="matrix(0.3059451,-2.9586281e-2,4.2229157e-2,0.3111526,-530.12905,-128.33652)" />
  </defs>
  <g
     transform="translate(-17.10493,-15.181464)"
     id="layer1">
    <g
       transform="matrix(2.1340374,0,0,2.1340374,784.00352,192.47679)"
       id="g10700">
      <g
         transform="matrix(0.7659149,0,0,1,40.151652,59.737034)"
         id="g3681">
        <g
           id="g3564">
          <path
             d="M -506.24217,-108.72388 L -463.96104,-112.81265 C -461.07235,-113.08237 -459.71029,-112.05976 -459.26337,-109.47742 L -458.52296,-104.31152 L -372.85676,-112.59583 C -371.37958,-112.73868 -370.02623,-111.64424 -369.82235,-110.14192 L -359.14929,-31.500818 C -358.9454,-29.998498 -359.97046,-28.674058 -361.44763,-28.531208 L -493.62379,-15.749168 C -495.10096,-15.606318 -496.45431,-16.700768 -496.6582,-18.203088 L -508.54051,-105.75427 C -508.74441,-107.25658 -507.71935,-108.58103 -506.24217,-108.72388 z"
             id="rect2392"
             style="fill:url(#linearGradient2536);fill-opacity:1;fill-rule:nonzero;stroke:url(#linearGradient3320);stroke-width:1.5;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
          <path
             d="M -462.97698,-112.48281 C -463.29155,-112.48758 -463.61589,-112.48445 -463.97698,-112.46208 L -506.25823,-109.74621 C -507.73541,-109.65144 -508.77463,-108.77335 -508.57073,-107.77669 L -500.98612,-68.946895 C -490.3678,-75.412584 -475.55251,-86.064051 -454.44573,-87.957069 C -413.19086,-91.618705 -391.54498,-98.700293 -369.74376,-103.1596 L -369.85198,-110.67914 C -370.05586,-111.67581 -371.40606,-112.41172 -372.88323,-112.31696 L -458.53948,-106.82302 L -459.28948,-110.24378 C -459.68053,-111.7428 -460.77496,-112.44941 -462.97698,-112.48281 z"
             id="path3436"
             style="opacity:0.32113821;fill:url(#linearGradient3451);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.5;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
          <path
             d="M -492.3596,-17.090788 C -493.83839,-16.951208 -495.19324,-18.020638 -495.39735,-19.488628 L -507.29272,-105.0387 C -507.49685,-106.50667 -506.47066,-107.80085 -504.99185,-107.94043"
             id="path3362"
             style="fill:none;fill-opacity:1;fill-rule:nonzero;stroke:url(#linearGradient3374);stroke-width:1.48357332;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;filter:url(#filter3384)" />
          <path
             d="M -507.12798,-107.50386 L -464.84685,-111.59264 C -461.95816,-111.86235 -460.5961,-110.83974 -460.14918,-108.2574 L -459.40877,-103.09151 L -373.74257,-111.37582 C -372.26539,-111.51867 -370.91204,-110.42422 -370.70816,-108.9219"
             id="path3330"
             style="fill:none;fill-opacity:1;fill-rule:nonzero;stroke:url(#linearGradient3360);stroke-width:1.5;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;filter:url(#filter3342)" />
          <rect
             width="41.653458"
             height="6.7793374"
             ry="1.332105"
             x="-490.92169"
             y="-157.32867"
             transform="matrix(0.9945444,-0.1043137,0.1043137,0.9945444,0,0)"
             id="rect3546"
             style="opacity:0.85772358;fill:url(#linearGradient3554);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.4765138;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
        </g>
        <g
           id="g3556">
          <path
             d="M -477.40032,-80.856207 L -342.45791,-94.236596 C -340.96502,-94.383839 -340.21936,-93.547653 -340.78602,-92.361755 L -356.52405,-30.600228 C -357.09074,-29.414318 -358.74879,-28.341068 -360.24169,-28.193828 L -493.82464,-15.018648 C -495.31754,-14.871408 -496.06319,-15.707598 -495.49652,-16.893508 L -481.11796,-78.44981 C -480.55128,-79.635707 -478.8932,-80.708969 -477.40032,-80.856207 z"
             id="path2403"
             style="fill:url(#linearGradient2533);fill-opacity:1;fill-rule:nonzero;stroke:url(#linearGradient3328);stroke-width:1.5;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
          <path
             d="M -350.50875,-56.711958 C -394.56805,-52.258608 -452.46288,-46.436738 -487.78999,-43.024458 L -493.69624,-17.805708 C -494.25373,-16.639028 -493.50868,-15.817108 -492.03999,-15.961958 L -360.63375,-28.930708 C -359.16506,-29.075558 -357.535,-30.139018 -356.9775,-31.305708 L -350.50875,-56.711958 z"
             id="path3453"
             style="opacity:0.8048782;fill:url(#linearGradient3474);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.5;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
          <path
             d="M -476.72364,-80.09756 L -343.96932,-93.260984 C -342.50065,-93.40584 -341.76708,-92.583213 -342.32455,-91.416544 L -357.80738,-30.656488 C -358.36489,-29.489798 -359.99605,-28.433948 -361.46474,-28.289098 L -492.88164,-15.327558 C -494.35032,-15.182708 -495.08388,-16.005338 -494.5264,-17.172018 L -480.381,-77.730182 C -479.8235,-78.89685 -478.19231,-79.952709 -476.72364,-80.09756 z"
             id="path3407"
             style="opacity:0.82113821;fill:url(#linearGradient3419);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.5;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
          <path
             d="M -343.13323,-93.481838 L -475.88323,-80.325588 C -477.3519,-80.180737 -478.98198,-79.117257 -479.53948,-77.950588 L -487.63323,-43.325588 C -470.15963,-51.340708 -450.44496,-57.770398 -433.44573,-59.638088 C -395.43261,-63.814536 -369.0427,-66.17379 -343.57073,-83.513088 L -341.50823,-91.638088 C -340.95076,-92.804757 -341.66456,-93.626697 -343.13323,-93.481838 z"
             id="path3421"
             style="opacity:0.51626012;fill:url(#linearGradient3737);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.5;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
          <path
             d="M -357.24772,-31.250098 C -357.80757,-30.102158 -359.44559,-29.063268 -360.92046,-28.920748 L -492.8905,-16.167438 C -494.36537,-16.024908 -495.10202,-16.834328 -494.54219,-17.982268 L -480.33724,-77.567549 C -479.7774,-78.715477 -478.13935,-79.754372 -476.66449,-79.896898"
             id="path3482"
             style="fill:none;fill-opacity:1;fill-rule:nonzero;stroke:url(#linearGradient3494);stroke-width:1.46685326;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;filter:url(#filter3500)" />
          <path
             d="M -478.56891,-79.880323 L -343.62651,-93.260712 C -342.13362,-93.407955 -341.38796,-92.571769 -341.95462,-91.385871 L -357.69265,-29.624348"
             id="path3504"
             style="fill:none;fill-opacity:1;fill-rule:nonzero;stroke:url(#linearGradient3540);stroke-width:1.5;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;filter:url(#filter3530)" />
        </g>
      </g>
      <rect
         width="148.64716"
         height="148.64716"
         ry="1.5435134"
         x="-359.36511"
         y="-83.079765"
         id="rect10698"
         style="opacity:1;fill:none;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.35283852;stroke-linecap:butt;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.71428576" />
    </g>
  </g>
</svg>

 

EDIT

Gah, realised my mistake..

should be

object type='image/svg+xml' data='images/folder.svg' width='28' height='28'></object>

Should have known as I've worked with svg's before.

Still not much luck though as scaling below certain value prevents it from rendering.. oh well can't win them all.

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.