I am using umbraco with a custom data type to attach files to a PDF. When I go and try to transfer the information with courier this does not get treansferred. I have tried to add an XPath and a regular expression to the courier.config but with no luck. Also tried umbraco support and they seemed to be stumpt by this as well.. Any help would be greatly appreciated. Here is what I have tried so far with the code:
I'm having problems with Courier too, so maybe we can help each other :)
Can you clarify your set up? As I understand it, you have a custom datatype that contains a reference to a Media node where the PDF is located? Or does it contain the location of a PDF in the filesystem? I can both of these Scenarios to work fine (link to Media and link to file) - I'm stuck with a link to a content node!
I have the problem with umbraco courier.Whenever i transfer any media file like pdf,doc,xls(except image files .gif,.png,.jpeg) from staging to live(destination environment), it doesnot transferring the media files.That means, the content nodes are getting transferred, but the files like pdf,doc,xls included with in that page is not getting transferred.
But there is not having an issue with image files as I mentioned above.
The umbraco version Using is : 4.0.2.1
The courier vesion using is : 1.3
Could anyone please suggest an idea about why this is happening?
Also, please suggest the solution for fixing the same.
Courier Not Transferring Custom Datatype Files
Hi All,
I am using umbraco with a custom data type to attach files to a PDF. When I go and try to transfer the information with courier this does not get treansferred. I have tried to add an XPath and a regular expression to the courier.config but with no luck. Also tried umbraco support and they seemed to be stumpt by this as well.. Any help would be greatly appreciated. Here is what I have tried so far with the code:
ProductDocuments.ascx
<%@ Control Language="VB" AutoEventWireup="false" CodeFile="ProductDocuments.ascx.vb" Inherits="usercontrols_datatype_ProductDocuments" %>
<asp:ListBox ID="ListBox1" runat="server" Width="300" Height="200"></asp:ListBox>
<asp:Button ID="btnDelete" runat="server" Text="Remove Item" />
<br />
<table>
<tr>
<td>Document:</td>
<td><asp:DropDownList ID="DropDownList1" runat="server"></asp:DropDownList></td>
</tr>
<tr>
<td>File:</td>
<td><asp:DropDownList ID="DropDownList2" runat="server"></asp:DropDownList></td>
</tr>
<tr>
<td></td>
<td><asp:Button ID="btnAdd" runat="server" Text="Add" /></td>
</tr>
</table>
<br />
<asp:HiddenField ID="hdnValue" runat="server" />
<br />
ProductDocuments.ascx.vb
Imports
System.Xml
Imports
umbraco.cms.businesslogic.media
Partial
usercontrols_datatype_ProductDocuments
System.Web.UI.UserControl
umbraco.editorControls.userControlGrapper.IUsercontrolDataEditor
XmlDocument()
umbraco.editorControls.userControlGrapper.IUsercontrolDataEditor.value
Get
'Return DropDownList1.SelectedValue
'Return HiddenField1.Value
'Return String.Empty
'Return hdnValue.Value
doc.InnerXml()
Get
)
Then
Try
doc.LoadXml(value)
LoadData()
'hdnValue.Value = doc.OuterXml().ToString()
Catch
doc.LoadXml(
)
Try
If
Set
Property
.Init
doc.LoadXml(
)
Sub
.Load
Then
'doc.LoadXml("<specs />")
hdnValue.Value = doc.OuterXml.ToString()
XmlDataSource()
xds.DataFile =
"/inc/product_documents.xml"
xds.XPath =
"//option"
DropDownList1.DataSource = xds
DropDownList1.DataTextField =
"name"
DropDownList1.DataValueField =
"name"
DropDownList1.DataBind()
DropDownList1.Items.Insert(0,
.Empty))
Media(2398)
m.Children
DropDownList2.Items.Add(
, f.Id, f.Text)))
Next
DropDownList2.Items.Insert(0,
.Empty))
Else
doc.LoadXml(hdnValue.Value)
If
Sub
LoadData()
ListBox1.Items.Clear()
= 1
)
ListBox1.Items.Add(
).Value, index))
index += 1
Next
hdnValue.Value = doc.OuterXml.ToString()
Sub
btnAdd.Click
'Response.Write("[[" & hdnValue.Value & "---" & doc.OuterXml.ToString() & "]]")
= DropDownList1.SelectedValue
Then
)
)
XmlAttribute
at = doc.CreateAttribute(
)
at.Value = name
node.Attributes.Append(at)
at = doc.CreateAttribute(
)
at.Value = value(1)
node.Attributes.Append(at)
at = doc.CreateAttribute(
)
at.Value = value(0)
node.Attributes.Append(at)
doc.DocumentElement.AppendChild(node)
LoadData()
If
DropDownList2.SelectedValue =
.Empty
DropDownList1.SelectedValue =
.Empty
Sub
btnDelete.Click
Then
'Response.Write("[[" & ListBox1.SelectedValue & "]]")
)
Then
node.ParentNode.RemoveChild(node)
LoadData()
If
If
Sub
'Protected Sub Page_PreRender(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.PreRender
' Dim debug As New TextBox()
' debug.Text = doc.OuterXml.ToString()
' debug.TextMode = TextBoxMode.MultiLine
' debug.Width = 400
' debug.Height = 400
' Me.Controls.Add(debug)
'End Sub
End
Any help would be greatly appreciated with this since we basically can't use courier until this is fixed..
Thanks
Hi,
I'm having problems with Courier too, so maybe we can help each other :)
Can you clarify your set up? As I understand it, you have a custom datatype that contains a reference to a Media node where the PDF is located? Or does it contain the location of a PDF in the filesystem? I can both of these Scenarios to work fine (link to Media and link to file) - I'm stuck with a link to a content node!
TTFN
Ant
Hi All,
I have the problem with umbraco courier.Whenever i transfer any media file like pdf,doc,xls(except image files .gif,.png,.jpeg) from staging to live(destination environment), it doesnot transferring the media files.That means, the content nodes are getting transferred, but the files like pdf,doc,xls included with in that page is not getting transferred.
But there is not having an issue with image files as I mentioned above.
The umbraco version Using is : 4.0.2.1
The courier vesion using is : 1.3
Could anyone please suggest an idea about why this is happening?
Also, please suggest the solution for fixing the same.
is working on a reply...