You are not logged in.

Dear visitor, welcome to krpano.com Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

  • "designsubway" started this thread

Posts: 40

Location: York, UK

Occupation: Graphic Designer

  • Send private message

1

Tuesday, August 24th 2010, 11:44am

www.domain.com error but not domain.com

Hi


I would be really grateful if someone could help me with this as I am banging my head against a brick wall!


I have recently downloaded the newest version of krpano (1.0.8.11) with a view to updating one of my sites with the newest version.
The only page I have done so far is http://scarborough360.co.uk/scarborough-…park-night.html
The problem that I have is that I get a security error when I view http://www.scarborough360.co.uk/scarboro…park-night.html instead (notice the www.)
I have tried using a crossdomain.xml file but I just can't get it to work.


crossdomain.xml

Source code

1
2
3
4
5
6
<?xml version="1.0" encoding="UTF-8"?>

<cross-domain-policy>
	<allow-access-from domain="*" />
</cross-domain-policy>
	




pano.xml

Source code

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
<krpano version="1.0.8" onstart="action(hidepr);" logkey="false" showerrors="false">

<action name="hidepr" >
set(progress.showload,none);
set(progress.showwait,none);
</action>

	<security>
    	<crossdomainxml url="http://www.scarborough360.co.uk/panoramas/skate01/crossdomain.xml" />
	</security>

	<view hlookat     ="0"
		vlookat       ="0"
		camroll       ="0"
		fov           ="1"
		fovmin        ="100"
		fovmax        ="100"
		maxpixelzoom  ="1"
		limitview     ="range"
		hlookatmin    ="NaN"
		hlookatmax    ="NaN"
		vlookatmin    ="NaN"
		vlookatmax    ="70.000000"
	/>

	<control usercontrol    ="all"
		mousetype      ="moveto"
		movetocursor   ="arrow"
		cursorsize     ="10.0"
		mouseaccelerate="0.60"
		mousespeed     ="1.00"
		mousefriction  ="0.80"
		headswing      ="0.00"
		keybaccelerate ="0.50"
		keybspeed      ="10.00"
		keybfriction   ="0.90"
		keybinvert     ="false"
		mousefovchange ="0"
		keybfovchange  ="0.75"
		fovspeed       ="3.00"
		fovfriction    ="0.90"
		keycodesleft   ="37"
		keycodesright  ="39"
		keycodesup     ="38"
		keycodesdown   ="40"
		keycodesin     ="107"
		keycodesout    ="109"
	/>

	<autorotate enabled="true" waittime="1.0" accel="0.8" speed="5" horizon="0" tofov="NaN" />			

	<display details="22" movequality="HIGHSHARP" stillquality="HIGHSHARP" />

	<preview type="CUBESTRIP" url="tiles/preview.jpg" />

	<image type="CUBE" multires="true" tilesize="470">
		<level tiledimagewidth="940" tiledimageheight="940">
			<left  url="tiles/l1_l_%0v_%0h.jpg" />
			<front url="tiles/l1_f_%0v_%0h.jpg" />
			<right url="tiles/l1_r_%0v_%0h.jpg" />
			<back  url="tiles/l1_b_%0v_%0h.jpg" />
			<up    url="tiles/l1_u_%0v_%0h.jpg" />
			<down  url="tiles/l1_d_%0v_%0h.jpg" />
		</level>
	</image>

</krpano>



html code

Source code

1
2
3
4
5
6
7
8
9
10
11
12
13
<div id="krpanoDIV">
  <noscript>
    <table width="100%" height="550"><tr valign="middle"><td><center>ERROR:<br /><br />Javascript not activated<br /><br /></center></td></tr></table>
  </noscript>
  </div>
  
  <script type="text/javascript" src="panoramas/skate01/swfkrpano.js"></script>
  
  <script type="text/javascript">
    var swf = createswf("/panoramas/skate01/krpano.swf", "krpanoSWFObject", "100%", "550", "#000000");
    swf.addVariable("xml","/panoramas/skate01/pano.xml");
    swf.embed("krpanoDIV");
  </script>



Any help would really be appreciated.
Thank you

  • "designsubway" started this thread

Posts: 40

Location: York, UK

Occupation: Graphic Designer

  • Send private message

2

Tuesday, August 24th 2010, 11:49am

Swapped it round so www.domain.com works but domain.com doesn't. Obviously this doesn't fix the issue though.

This post has been edited 1 times, last edit by "designsubway" (Aug 24th 2010, 12:01pm)


3

Tuesday, August 24th 2010, 12:26pm

To digress a little, allowing access to the same pages from two different urls is not a good idea in terms of seo. Choose for yourself whether you want http://www.scarborough360.co.uk/ or http://scarborough360.co.uk/ and then set an appropriate apache mod-rewrite so that your chosen name works.

  • "designsubway" started this thread

Posts: 40

Location: York, UK

Occupation: Graphic Designer

  • Send private message

4

Tuesday, August 24th 2010, 12:35pm

Fair enough, solved with:

Source code

1
2
RewriteCond %{HTTP_HOST} ^scarborough360.co.uk [NC]
RewriteRule ^(.*)$ http://www.scarborough360.co.uk/$1 [L,R=301]

in the .htaccess file.

5

Tuesday, August 24th 2010, 1:41pm

Hi,

an additional note - I think the main problem comes from the html "base href" setting:

Source code

1
<base href="http://www.scarborough360.co.uk/scarborough-panoramas/hairy-bobs-skatepark-night.html" />


because when using relative paths for krpano and in the xml files, no crossdomain access would happen...

best regards,
Klaus