<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
I had commented out the whole test...<br>
<br>
<div class="moz-cite-prefix">Op 22-11-2012 13:38, Fay Cross schreef:<br>
</div>
<blockquote
cite="mid:A44245E8C549494D9561A9727B89EEC80ACF9BB2B6@EXCHANGE1.ad.nottingham.ac.uk"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<meta name="Generator" content="Microsoft Word 12 (filtered
medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:Wingdings;
panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
{font-family:Wingdings;
panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p
{mso-style-priority:99;
mso-margin-top-alt:auto;
margin-right:0cm;
mso-margin-bottom-alt:auto;
margin-left:0cm;
font-size:12.0pt;
font-family:"Times New Roman","serif";}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
{mso-style-priority:99;
mso-style-link:"Balloon Text Char";
margin:0cm;
margin-bottom:.0001pt;
font-size:8.0pt;
font-family:"Tahoma","sans-serif";}
span.EmailStyle18
{mso-style-type:personal-reply;
font-family:"Calibri","sans-serif";
color:#1F497D;}
span.BalloonTextChar
{mso-style-name:"Balloon Text Char";
mso-style-priority:99;
mso-style-link:"Balloon Text";
font-family:"Tahoma","sans-serif";}
.MsoChpDefault
{mso-style-type:export-only;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
<div class="WordSection1">
<p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Yes,
(why didn’t I think of that doh). I think I need to sort
through the html5 stuff too as although it’s just two
folders (common_html5 and models_html5) there might be some
stuff in there that’s not needed.<o:p></o:p></span></p>
<p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Cheers
for your help Pat </span><span
style="font-size:11.0pt;font-family:Wingdings;color:#1F497D">J</span><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<div style="border:none;border-top:solid #B5C4DF
1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal" style="margin-left:36.0pt"><b><span
style="font-size:10.0pt;font-family:"Tahoma","sans-serif""
lang="EN-US">From:</span></b><span
style="font-size:10.0pt;font-family:"Tahoma","sans-serif""
lang="EN-US"> <a class="moz-txt-link-abbreviated" href="mailto:xerte-dev-bounces@lists.nottingham.ac.uk">xerte-dev-bounces@lists.nottingham.ac.uk</a>
[<a class="moz-txt-link-freetext" href="mailto:xerte-dev-bounces@lists.nottingham.ac.uk">mailto:xerte-dev-bounces@lists.nottingham.ac.uk</a>] <b>On
Behalf Of </b>Pat Lockley<br>
<b>Sent:</b> 22 November 2012 12:33<br>
<b>To:</b> For Xerte technical developers<br>
<b>Subject:</b> [Xerte-dev] Re: Export problem<o:p></o:p></span></p>
</div>
<p class="MsoNormal" style="margin-left:36.0pt"><o:p> </o:p></p>
<p class="MsoNormal" style="margin-left:36.0pt">make it an or
for either condition<br>
<br>
so if html model folder found the number =<br>
<br>
if not<br>
<br>
then number = <br>
<br>
The big thing is that this code has been re done in my branch
*shoots self*<o:p></o:p></p>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:36.0pt"><o:p> </o:p></p>
<div>
<p class="MsoNormal" style="margin-left:36.0pt">On Thu, Nov
22, 2012 at 12:24 PM, Fay Cross <<a
moz-do-not-send="true"
href="mailto:Fay.Cross@nottingham.ac.uk" target="_blank">Fay.Cross@nottingham.ac.uk</a>>
wrote:<o:p></o:p></p>
<div>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:36.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Thanks,
works in them all now, although I had to change the
explode bit to 8 (because now the export includes
the html5 stuff and there’s horribly nested folders
in the jquery ui css). If you’re importing an old
project without the html5 stuff in it won’t catch
projects where the zip has an extra folder in though
– is that going to be a big problem?</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:36.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<div style="border:none;border-top:solid #B5C4DF
1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt"><b><span
style="font-size:10.0pt;font-family:"Tahoma","sans-serif""
lang="EN-US">From:</span></b><span
style="font-size:10.0pt;font-family:"Tahoma","sans-serif""
lang="EN-US"> <a moz-do-not-send="true"
href="mailto:xerte-dev-bounces@lists.nottingham.ac.uk"
target="_blank">xerte-dev-bounces@lists.nottingham.ac.uk</a>
[mailto:<a moz-do-not-send="true"
href="mailto:xerte-dev-bounces@lists.nottingham.ac.uk"
target="_blank">xerte-dev-bounces@lists.nottingham.ac.uk</a>]
<b>On Behalf Of </b>Pat Lockley<br>
<b>Sent:</b> 22 November 2012 12:13</span><o:p></o:p></p>
<div>
<div>
<p class="MsoNormal" style="margin-left:36.0pt"><br>
<b>To:</b> For Xerte technical developers<br>
<b>Subject:</b> [Xerte-dev] Re: Export problem<o:p></o:p></p>
</div>
</div>
</div>
<div>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt"> <o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt">ok
add an or on the mimetype if<span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">
for ‘application/octet-stream’<br>
<br>
and try swapping the 3, for a 4</span><o:p></o:p></p>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;margin-bottom:12.0pt;margin-left:72.0pt"> <o:p></o:p></p>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt">On
Thu, Nov 22, 2012 at 11:59 AM, Fay Cross <<a
moz-do-not-send="true"
href="mailto:Fay.Cross@nottingham.ac.uk"
target="_blank">Fay.Cross@nottingham.ac.uk</a>>
wrote:<o:p></o:p></p>
<div>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Ok,
in Firefox it fails because the file
type appears as
‘application/octet-stream’</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">In
IE8 and Chrome it fails because of...</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif"">if(count(explode("/",$y))==3){</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt;text-indent:36.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif"">die(IMPORT_ZIP_FOLDER_LEVEL
. "****");</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">$y
is ‘wizards/en-GB/data.xwd’ and it
doesn’t like this because it thinks that
means ‘The files in your zip folder need
to be in the main folder, not within
another folder in the zip.’</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<div style="border:none;border-top:solid
#B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:108.0pt"><b><span
style="font-size:10.0pt;font-family:"Tahoma","sans-serif""
lang="EN-US">From:</span></b><span
style="font-size:10.0pt;font-family:"Tahoma","sans-serif""
lang="EN-US"> <a
moz-do-not-send="true"
href="mailto:xerte-dev-bounces@lists.nottingham.ac.uk"
target="_blank">xerte-dev-bounces@lists.nottingham.ac.uk</a>
[mailto:<a moz-do-not-send="true"
href="mailto:xerte-dev-bounces@lists.nottingham.ac.uk"
target="_blank">xerte-dev-bounces@lists.nottingham.ac.uk</a>]
<b>On Behalf Of </b>Pat Lockley<br>
<b>Sent:</b> 22 November 2012 11:15<br>
<b>To:</b> For Xerte technical
developers<br>
<b>Subject:</b> [Xerte-dev] Re: Export
problem</span><o:p></o:p></p>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:108.0pt"> <o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:108.0pt">Stupid
question response - firebug console (well
the chrome console) should show all the
text a web page returns, so a php echo
should appear in firebug<br>
<br>
*installs firebug*<br>
<br>
Yep :)<br>
<br>
If you look in the code - there is an echo
of that error (might be in the language
file now as a text string, so cross ref)
you'll see what condition generates that
error, and then work back through the
logic.<o:p></o:p></p>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;margin-bottom:12.0pt;margin-left:108.0pt"> <o:p></o:p></p>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:108.0pt">On
Thu, Nov 22, 2012 at 11:01 AM, Fay
Cross <<a moz-do-not-send="true"
href="mailto:Fay.Cross@nottingham.ac.uk"
target="_blank">Fay.Cross@nottingham.ac.uk</a>>
wrote:<o:p></o:p></p>
<div>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:108.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Stupid
question alert – would php echos
appear in the firebug console?</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:108.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:108.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Incidentally,
I just tried importing in IE
instead and got a different
error to the Firefox one – ‘The
files in your zip folder need to
be in the main folder, not
within another folder in the
zip.’ (they’re not in another
folder)</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:108.0pt"><span
style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<div
style="border:none;border-top:solid
#B5C4DF 1.0pt;padding:3.0pt 0cm
0cm 0cm">
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:144.0pt"><b><span
style="font-size:10.0pt;font-family:"Tahoma","sans-serif""
lang="EN-US">From:</span></b><span
style="font-size:10.0pt;font-family:"Tahoma","sans-serif""
lang="EN-US"> <a
moz-do-not-send="true"
href="mailto:xerte-dev-bounces@lists.nottingham.ac.uk"
target="_blank">xerte-dev-bounces@lists.nottingham.ac.uk</a>
[mailto:<a
moz-do-not-send="true"
href="mailto:xerte-dev-bounces@lists.nottingham.ac.uk"
target="_blank">xerte-dev-bounces@lists.nottingham.ac.uk</a>]
<b>On Behalf Of </b>Pat
Lockley<br>
<b>Sent:</b> 22 November 2012
10:28<br>
<b>To:</b> For Xerte technical
developers<br>
<b>Subject:</b> [Xerte-dev]
Re: Export problem</span><o:p></o:p></p>
</div>
<div>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:144.0pt"> <o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:144.0pt">the
"you can only import zip
files" is usually a mime type
issue.<br>
<br>
Look in import.php for the
first if statement that checks
the mime type of the file.<br>
<br>
If you echo that variable and
then track in console or
fiddler you could debug that
part.<br>
<br>
Sometimes mozilla and chrome
report different mimetypes to
IE, so it might be that as
well.<o:p></o:p></p>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;margin-bottom:12.0pt;margin-left:144.0pt"> <o:p></o:p></p>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:144.0pt">On
Thu, Nov 22, 2012 at 10:04
AM, Fay Cross <<a
moz-do-not-send="true"
href="mailto:Fay.Cross@nottingham.ac.uk"
target="_blank">Fay.Cross@nottingham.ac.uk</a>>
wrote:<o:p></o:p></p>
<div>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:144.0pt">I
know this is something
that comes up a lot
but even using the
current files from the
toolkits svn set up in
xampp I can’t export
and then import a
project. The export
(as archive zip) seems
to works ok – all the
expected files are in
the zip. But when I
try to import it I get
an error ‘You can only
import Zip files’<o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:144.0pt"> <o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:144.0pt">Also,
I the language options
check boxes on the
editor are still not
appearing correctly –
wasn’t this fixed last
week?<o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:144.0pt"> <o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:144.0pt">Thanks<o:p></o:p></p>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;margin-bottom:12.0pt;margin-left:144.0pt"> <o:p></o:p></p>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;margin-bottom:12.0pt;margin-left:144.0pt"><br>
_______________________________________________<br>
Xerte-dev mailing list<br>
<a moz-do-not-send="true"
href="mailto:Xerte-dev@lists.nottingham.ac.uk" target="_blank">Xerte-dev@lists.nottingham.ac.uk</a><br>
<a moz-do-not-send="true"
href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte-dev"
target="_blank">http://lists.nottingham.ac.uk/mailman/listinfo/xerte-dev</a><o:p></o:p></p>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:144.0pt"> <o:p></o:p></p>
</div>
</div>
</div>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;margin-bottom:12.0pt;margin-left:108.0pt"> <o:p></o:p></p>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;margin-bottom:12.0pt;margin-left:108.0pt"><br>
_______________________________________________<br>
Xerte-dev mailing list<br>
<a moz-do-not-send="true"
href="mailto:Xerte-dev@lists.nottingham.ac.uk"
target="_blank">Xerte-dev@lists.nottingham.ac.uk</a><br>
<a moz-do-not-send="true"
href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte-dev"
target="_blank">http://lists.nottingham.ac.uk/mailman/listinfo/xerte-dev</a><o:p></o:p></p>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:108.0pt"> <o:p></o:p></p>
</div>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;margin-bottom:12.0pt;margin-left:72.0pt"><o:p> </o:p></p>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;margin-bottom:12.0pt;margin-left:72.0pt"><br>
_______________________________________________<br>
Xerte-dev mailing list<br>
<a moz-do-not-send="true"
href="mailto:Xerte-dev@lists.nottingham.ac.uk"
target="_blank">Xerte-dev@lists.nottingham.ac.uk</a><br>
<a moz-do-not-send="true"
href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte-dev"
target="_blank">http://lists.nottingham.ac.uk/mailman/listinfo/xerte-dev</a><o:p></o:p></p>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:72.0pt"> <o:p></o:p></p>
</div>
</div>
</div>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:36.0pt"><br>
<br>
<o:p></o:p></p>
</div>
<p class="MsoNormal"
style="mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:36.0pt"><br>
_______________________________________________<br>
Xerte-dev mailing list<br>
<a moz-do-not-send="true"
href="mailto:Xerte-dev@lists.nottingham.ac.uk">Xerte-dev@lists.nottingham.ac.uk</a><br>
<a moz-do-not-send="true"
href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte-dev"
target="_blank">http://lists.nottingham.ac.uk/mailman/listinfo/xerte-dev</a><o:p></o:p></p>
</div>
<p class="MsoNormal" style="margin-left:36.0pt"><o:p> </o:p></p>
</div>
</div>
<br>
<br>
<br>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
Xerte-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Xerte-dev@lists.nottingham.ac.uk">Xerte-dev@lists.nottingham.ac.uk</a>
<a class="moz-txt-link-freetext" href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte-dev">http://lists.nottingham.ac.uk/mailman/listinfo/xerte-dev</a>
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
--
Tom Reijnders
TOR Informatica
Chopinlaan 27
5242HM Rosmalen
Tel: 073 5226191
Fax: 073 5226196
</pre>
</body>
</html>