We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Base tag breaks diagram's gridlines

Greetings,

Adding <base rel='nofollow' href="/"> to the HTML causes the diagram's gridlines not to appear. The cause of the problem is that the base tag applies to SVG references which are used to reference the gridlines pattern (full description and workaround here: https://github.com/meanjs/mean/issues/1224 )

I applied the workaround by changing the reference to include the current full path so that the base tag would not apply to it. For example, if the diagram's ID is "diagram", the following code makes the gridlines appear:

$('#diagram_canvaspattern_gridline').attr('fill', `url(${location.pathname}${location.search}#diagram_canvaspattern_grid)`);

I propose adding the location pathname and search to the fill attribute url as part of the diagram building code to have it working out of the box when base tag is present.

3 Replies

SG Shyam G Syncfusion Team June 2, 2016 04:57 AM UTC

Hi Gabriel, 

Sorry for the delay. 

If we use base tag in the SVG, it will override all the relative URL in the page. So please confirm us why you are using base tag in your application, so that we can provide an alternate solution to you. please refer to the below link in which they have said to avoid the base tag. 


Regards, 
Shyam G 



GA Gabriel Axel June 3, 2016 08:12 PM UTC

Hi Shyam,

I configured my development server so that I would not need to set the base tag, so no problem anymore.

Thanks,

Gabi


KR Kameshwaran R Syncfusion Team June 6, 2016 10:49 AM UTC

Hi Gabriel, 
Thenks for the update. 
please let me know if any further clarification on this. 
Regards, 
Kameshwaran R. 


Loader.
Up arrow icon