Quantcast
Channel: ActiveTopics
Viewing all 72689 articles
Browse latest View live

How to Create my own "Starter" Site

$
0
0

I would appreciate any suggestions you might have on setting up my own umbraco "starter" site using Umbraco in Visual Studio (not the cloud). A boilerplate of sorts.

My starter site would include a base set of:

  • Views
  • Doctypes
  • Javascript
  • Css

I know how to create this content. The part I'm unsure of in terms of best practices is how to incorporate this starter site in subsequent children sites.

Thanks in advance!


html-minifier

select image disabled

$
0
0

Using Umbraco version 8.5.4 and doctypegrid editor 1.1.0. When I use the image embed the the select is always disabled.

enter image description here

Storage Not Working - Labels Reversed

$
0
0

I have three Formulate forms on a site - one of them stores data as expected, however the other two don't. I can see the POST happen in the inspector (with a 200 code), but nothing gets stored in the DB.

I don't have any other handlers on these forms - just wanting to store to DB.

Not sure if it's relevant, but the form that is working was created on my dev machine and uploaded. The two that aren't working were created on the live server.

Another separate issue is that I just upgraded to 3.2.1 (to see if it fixed the above) and now all my forms have the labels after the control! Any idea what could be causing that?

Thanks for any help.

How to get determine the type in Nested Content

$
0
0

I got stuck on this so just some general information.

I needed to determine the type of what the Nested Content elements were. And based on the Umbraco 8 documentation for Nested Content, it was not clear, because I have multiple different types of nested content with different property values. That said, here is my solution.

It got the type by using ContentType.Alias

@{
 var items = Model.Value<IEnumerable<IPublishedElement>>("homepageSections");

  foreach (var item in items)
  {

    if (item.ContentType.Alias == "homepageArticles"){

      //Show selected articles

    }else if (item.ContentType.Alias == "homepageEvents"){

        //Show selected articles

    }else{}

  }@*End foreach*@

}

Why am I getting a "Type Ahead" error in Umbraco 8.5 tags

$
0
0

Why am I getting a "Type Ahead" error in Umbraco 8.5 tags

I am getting an error on my property with the Type ahead. Any ideas why? Should I file it as a bug?

TypeError: Cannot read property 'typeahead' of undefined
    at umbTagsEditorController.addTag (umbraco.directives.js?cdv=1991242412:9063)
    at fn (eval at compile (angular.js?cdv=1991242412:16387), <anonymous>:4:162)
    at callback (angular.js?cdv=1991242412:28815)
    at Scope.$eval (angular.js?cdv=1991242412:19356)
    at Scope.$apply (angular.js?cdv=1991242412:19455)
    at HTMLInputElement.<anonymous> (angular.js?cdv=1991242412:28819)
    at HTMLInputElement.dispatch (jquery.min.js?cdv=1991242412:2)
    at HTMLInputElement.v.handle (jquery.min.js?cdv=1991242412:2)

Dynamic colour picker based on hostname

$
0
0

So I'm developing sort of a multi-site setup on a single Umbraco instance (two root nodes with different hostnames set)

A lot of the document types are shared, but one thing in particular I wish I could do is have the colour picker data type on some of these document types change their available colours. Currently I'd need to copy this document type and add a different colour picker if I wanted to do this.

I could just replace the picker with dropdown/radio with "primary", "secondary", etc. but a working dynamic colour picker would be cooler.

Is there some easier way that I'm missing, or would it be possible to implement such functionality as a custom data type or similar?

Get unpublished page as IPublishedContent

$
0
0

I have a page that has never been published. How can I fetch this particular page as IPublishedContent using your services?

I know that I can fetch it as IContent, but as far as I can tell, there is no way to convert it to IPublishedContent in Umbraco 8.


ExternalIndex search

$
0
0

I am trying to prevent an ExternalIndex search from looking into various property aliases. Is there a way to do this? It is the basic uSkinned logic for a search which I understand uses ExternalIndex

How to add custom context menu item?

$
0
0

I would like to add a custom menu item and write functionality for that. Is that possible.?
Any help is appreciable

One form to send multiple emails to different addresses with different titles?

$
0
0

Hi everyone,

I've got a query regarding the feasibility of something and I'm hoping someone who's spent a bit more time working on forms can advise if it's possible !

What I'd like is a form where a user completes their details at the top (e.g. name, email address etc) then they're asked a series of questions like:

  • Do you have a google account?
  • Do you have a facebook account?
  • Do you have a Twitter account?

If they answer yes to one (or more of these) an email is sent out. E.g. answer yes to Google and an email titled "Google email" goes to google@mydomain.com.

So if they answer yes to all three, three separate emails go out to different email addresses with email titles that are different.

In an absolutely ideal world I'd just have the initial user details and the pertinent question set sent out per different email. E.g. Answer yes to Twitter account, and an email titled "twitter" goes to xxx@mydomain.com with a subject of Twitter and it contains the initial user details and the answer to the Twitter question (but not the answer to the Google/Facebook question)

Has anyone tackled anything like this previously?

Environment: Umb 7.15.1 & Forms 7.0.6 (though if it helps I could bump them to 15.3 & 7.1.3)

UmbracoContext issues in hangfire/service job. (possible Dependency Injection)

$
0
0

Hi.

I'm using the LightInject Dependency Injection and running Hangfire to do some scheduled tasks. I think I've gotten Hangfire to work using one of two methods:

One by mocking a HttpContext when resolving the Scope of Lightinject, or two - by using another container for Hangfire and re-registering all services from the existing container.

Both of these seems to work. My issue comes from the application layer which I'm calling from my Hangfire job.

Suppose the following simplified example: From Hangfire I'm calling MyService.MyMethod() which needs to lookup content from Umbraco. I am doing the following simplified:

public class MyService : IMyService
{
    private readonly IUmbracoContextFactory _umbracoContextFactory;

    public MyService (IUmbracoContextFactory umbracoContextFactory)
    {
        _umbracoContextFactory = umbracoContextFactory;
    }

  public void MyMethod()
 {
       using (var contextFactory = _umbracoContextFactory.EnsureUmbracoContext())
        {                
            var myContent = contextFactory.UmbracoContext.Content.GetAtRoot().OfType<MyContent>()?.FirstOrDefault();
        }
 }
}

This does seem to work and I can view the correct content in myContent.

However afterwards, from somewhere, I also get a null pointer exception with the stacktrace

at Umbraco.Web.Templates.TemplateUtilities.ParseInternalLinks(String text, Boolean preview, UmbracoContext umbracoContext)
       at Umbraco.Web.PropertyEditors.ValueConverters.TextStringValueConverter.ConvertSourceToIntermediate(IPublishedElement owner, IPublishedPropertyType propertyType, Object source, Boolean preview)
       at Umbraco.Core.Models.PublishedContent.PublishedPropertyType.ConvertSourceToInter(IPublishedElement owner, Object source, Boolean preview)
       at Umbraco.Web.PublishedCache.NuCache.Property.GetInterValue(String culture, String segment)
       at Umbraco.Web.PublishedCache.NuCache.Property.GetValue(String culture, String segment)
       at Umbraco.Web.PublishedPropertyExtension.Value[T](IPublishedProperty property, String culture, String segment, Fallback fallback, T defaultValue)
       at Umbraco.Web.PublishedContentExtensions.Value[T](IPublishedContent content, String alias, String culture, String segment, Fallback fallback, T defaultValue)

This time the UmbracoContext is null in ParseInternalLinks It seems because "something" else is calling NuCache (perhaps a rendering that's triggered in the background or something?), but I don't understand what that is and I cannot seem to trace it back.

Does anybody have something that can help me shed some light on the issue and maybe point out where I am taking a wrong turn?

Thanks in advance.

Redirect 301 Server Error

$
0
0

Hello,

I have an Umbraco environment version 7.9.0 and I have this code:

@inherits Umbraco.Web.Mvc.UmbracoTemplatePage
@{
    Layout = "Master.cshtml";

    // This page shows nothing, only redirects to index page.
   var indexPage = Model.Content.GetPropertyValue<IPublishedContent>("indexPage");
   if (indexPage != null)
   {    
         Response.Redirect(indexPage.Url, false);
   }
   else
   {
      var results = Model.Content.Children.Where(x => x.Name.ToLower() == "index");
       if (results.Any())
       {        
        Response.Redirect(indexPage.Url, false);
       }
   }
  }

To put in context, I have two machines in two AWS servers and a AWS Load Balancer. The URL I am trying to reach is the URL of the load balancer and it decides which machine to use.

The problem is the Response.Redirect is giving a 302 code and I need to get a 301 so I changed Response.Redirect to Response.RedirectPermanent. After changing it the server is thowing a 503 error but if I remove the cookies it works again, and if I remove the cookies it throws the error again and so on.

Have you ever had this problem or something similar?

Thank you

Reference Content from another Umbraco site

$
0
0

Just wondering if I needed to reference / pull content from another Umbraco instance what would the best method be?

Unable to save document type for Multinode Treepicker in "Allow items of type" Field.

$
0
0

I am using Umbraco version 8.5.4

Allow items of type doesn't allow to save the document type.

Scenario:

1- Create new Multinode Treepicker Datatype.

2- Select Node Type

3- Now Allow Items of Type and select document type.

4- Click Save the changes.

Now when you save the changes you will see that the document type is removed from the Allow Items of Type

Please help me out Thanks

enter image description here


Nested Content Image Name as Template Label

$
0
0

Hi there,

I'm using nested content to create a component with an image and would like to know if it's possible to display the image name as the template label for that Doc Type.

If I use {{image}} I get the Umbraco media reference url. ie. umb://media/197d7b7f087c44d8aac778f6e1900c0b but is there an easy way to supply the image name?

Thanks, Luke

Umbraco 8 | Hangfire | Get Content Errors - Custom properties are all null

$
0
0

Hi Guys,

I am wondering if anyone has experienced this issue.

I am using Hangfire to handle scheduled tasks. I am also using dependency injection within Hangfire to get to my content.

When I get a content node within Hangfire for some reason all my custom properties are null and also throwing an exception.

Please see attache. enter image description here

This is also my method within my ISubscriberHelper class.

public JobAlertSubscriber GetJobAlertSubscriber(int Id)
        {
            JobAlertSubscriber jobAlertSubscriber;

            using (UmbracoContextReference umbracoContextReference = _umbracoContextFactory.EnsureUmbracoContext())
            {
                IPublishedContentCache contentHelper = umbracoContextReference.UmbracoContext.Content;
                jobAlertSubscriber = contentHelper.GetById(Id) as JobAlertSubscriber;
            }

            return jobAlertSubscriber;
        }

I'm assuming that because we are faking the context to acheive dependency injection within Hangfire there is some issues that are still not ironed out.

I also tried to look up the property values my trying to call the GetProperty methods on the content node and this through the same errors.

umbraco site moving from aws windows server to the azure webapp

$
0
0

Hi guys,

Could anyone please help me with the below scenario?

we are migrating the umbraco site which was hosted on aws windows server to azure webapp.

what we did is....... we have copied the entier root folder from the inet pub on windows server and copied to the newly created azure webapp. Taken backup of aws rds databse backup and imported to the newly created the sql paas database on azure and changed the connection strings. Also copied the media from the s3 storage account to azure storage account.

Right now we are facing the issue after deploying into the new azure environment. is there any documnetation whcih explains step by step?

please help me this is high priority for me .

Thanks in advance

richie

Umbraco 8.3 index lock error

$
0
0

Getting the dreaded "Cannot index queue items, the index is currently locked" in the LogViewer and when I go to "Settings"->"Examine Management" I get "Failed to retrieve indexer details" error. Anybody know what's up?

Site is running on Unoeuro (Now Simply.com).

Do I need to delete any temp files maybe?

eCommerce crash my umbraco

$
0
0

Hello every one i tried to install eCommerce to umbraco latest but it all crash my umbraco is there any good eCommerce for virgin 8.5

Viewing all 72689 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>