• dotnetnuke 头像调用 头像缩放


            public static string GetProfileImage(int userId, int width, int height)
            {         
                return "~/profilepic.ashx?userid=" + userId.ToString() + "&w=" + width.ToString() + "&h=" + height.ToString();
            }

    参与网站

    http://www.ventrian.com/blog/getting-user-profile-image-paths-in-dotnetnuke

    Luckily, this is a fairly trivial task with DotNetNuke:

    protected string GetProfileImage(int userId)
    {
        return Page.ResolveUrl("~/profilepic.ashx?userid=" + userId.ToString());
    }

    By default, it looks to be restricted to a maximum width and height of 55px. However, you can pass in parameters to control the width & height.

    protected string GetProfileImage(int userId, int width, int height)
    {
        return Page.ResolveUrl("~/profilepic.ashx?userid=" + userId.ToString() & "&w=" & width.ToString() & "&h=" & height.ToString());
    }


    http://www.ventrian.com/blog/better-profile-pictures-in-dotnetnuke
    <img alt="Profile Avatar" src="/profilepic.ashx?userId=[USER:USERID]&h=64&w=64" width="64" height="64">

  • 相关阅读:
    iOS controller 和 window 图层
    iOS CGAffineTransform 仿射变换
    iOS UIButton的UIEdgeInsets
    iOS UI的动态布局
    iOS 栅格动态布局
    iOS 系统键盘几个类型
    iOS 金融类高精度处理
    Sublime Text (崇高文本)
    iOS 静态库——制作bundle
    iOS 静态库——制作Framework
  • 原文地址:https://www.cnblogs.com/pengfeiwang/p/4373651.html
Copyright © 2020-2023  润新知